startjava opened a new issue, #19717:
URL: https://github.com/apache/pulsar/issues/19717

   ### Search before asking
   
   - [X] I searched in the [issues](https://github.com/apache/pulsar/issues) 
and found nothing similar.
   
   
   ### Version
   
   i use config:
   backlogQuotaCheckIntervalInSeconds=1
   ---------------------------------------------------------
                   long sizeLimit = 50000L;// 50KB
                   BacklogQuota.RetentionPolicy policy = 
BacklogQuota.RetentionPolicy.producer_request_hold;
                   BacklogQuota quota = BacklogQuota.builder()
                           .limitSize(sizeLimit)
                           .retentionPolicy(policy)
                           .build();
                   admin.namespaces().setBacklogQuota(myTenant + "/" + 
myNameSpace3, quota);
   -----------------------------------------------------------------
   send big mesasge,console print result:
   2023-03-06 11:42:10,send big message !
   2023-03-06 11:42:11.411 ERROR 41432 --- [r-client-io-8-1] 
o.a.pulsar.client.impl.ProducerImpl      : 
[persistent://my-tenant/my-namespace3/my-topic6] [standalone-49-255] Failed to 
create producer: 
{"errorMsg":"org.apache.pulsar.broker.service.BrokerServiceException$TopicBacklogQuotaExceededException:
 Cannot create producer on topic with backlog quota 
exceeded","reqId":1989443099668145054, "remote":"/192.168.2.59:6650", 
"local":"/192.168.2.57:55759"}
   ----------------------------------------------------
   time interval is 1 second ! it is right !
   
   -------------but use 
time-----------------------------------------------------
                   int timeLimit = 5;// 单位是second,5秒
                   BacklogQuota.RetentionPolicy policy = 
BacklogQuota.RetentionPolicy.producer_request_hold;
                   BacklogQuota quota = BacklogQuota.builder()
                           .limitTime(timeLimit)
                           .retentionPolicy(policy)
                           .build();
                   admin.namespaces().setBacklogQuota(myTenant + "/" + 
myNameSpace4, quota, BacklogQuota.BacklogQuotaType.message_age);
   ------------------------------------------------------------
   console print :
   2023-03-06 11:50:21,message end !
   2023-03-06 11:52:21.411 ERROR 20796 --- [r-client-io-8-1] 
o.a.pulsar.client.impl.ProducerImpl      : 
[persistent://my-tenant/my-namespace4/my-topic7] [standalone-49-280] Failed to 
create producer: 
{"errorMsg":"org.apache.pulsar.broker.service.BrokerServiceException$TopicBacklogQuotaExceededException:
 Cannot create producer on topic with backlog quota 
exceeded","reqId":850998466639597395, "remote":"/192.168.2.59:6650", 
"local":"/192.168.2.57:57255"}
   ---------------------------------------------------------
   time interval 120 second,2 minute!!!! it is error ??
   
   
   ### Minimal reproduce step
   
   ?
   
   ### What did you expect to see?
   
   ?
   
   ### What did you see instead?
   
   ?
   
   ### Anything else?
   
   ?
   
   ### Are you willing to submit a PR?
   
   - [ ] I'm willing to submit a PR!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to