ronfarkash commented on a change in pull request #11372:
URL: https://github.com/apache/pulsar/pull/11372#discussion_r675785986
##########
File path:
pulsar-common/src/main/java/org/apache/pulsar/common/util/RateLimiter.java
##########
@@ -203,7 +203,7 @@ public synchronized boolean tryAcquire(long acquirePermit) {
*
* @return returns 0 if permits is not available
*/
- public synchronized long getAvailablePermits() {
+ public long getAvailablePermits() {
Review comment:
This change is necessary to prevent a dead lock when two rate limiters
will attempt to use `getAvailablePermits()` and is required for the fix.
--
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]