shibd opened a new pull request, #16671:
URL: https://github.com/apache/pulsar/pull/16671

   ### Motivation
   
   #16663
   
   Currently, `MaxUnackedMessagesOnConsumer` do not precisely control. 
   
   If one 
[Consumer](https://github.com/apache/pulsar/blob/master/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/Consumer.java)
  `MaxUnackedMessagesOnConsumer` is 100, and current `unackedMessages` size is 
95. 
   
   When 10 messages are read again, they may be sent to this consumer again. 
Because this check `unackedMessages:95` < `MaxUnackedMessagesOnConsumer:100` 
not blocked, and **105** unacked messages are eventually sent to the consumer.
   
   ### Modifications
   
   I don't think this is a problem, we don't need to make changes on the broker 
side. 
   
   We can modify the size of `consumer.receiverQueue` in the unit test to be 
**1**, so as to ensure that each time the message is read from bk, it is 1 to 
make this test stable.
   
   ### Documentation
   
   Tell the user that the value is not precisely controlled.
   
   - [x] `doc` 
   (Your PR contains doc changes)
   
   


-- 
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