dlg99 commented on PR #3348:
URL: https://github.com/apache/bookkeeper/pull/3348#issuecomment-1162140453

   @lordcheng10 +1 to Matteo's concern about performance.
   Original implementation https://github.com/apache/bookkeeper/pull/1309 
concentrated on "lightweight" over "precise size" hence it is optimistic and I 
think this is ok.
   checkQueue() and methods using it are not synchronized, it is possible to 
call it from multiple threads, pass the check and end up with more tasks in 
queue than the soft limit. Performance benefits eher outweigh the precision.


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