kaushik-develop commented on a change in pull request #11916:
URL: https://github.com/apache/pulsar/pull/11916#discussion_r702057120
##########
File path:
pulsar-broker/src/main/java/org/apache/pulsar/broker/resourcegroup/ResourceQuotaCalculatorImpl.java
##########
@@ -80,6 +74,12 @@ public long computeLocalQuota(long confUsage, long myUsage,
long[] allUsages) th
float myUsageFraction = (float) myUsage / totalUsage;
float calculatedQuota = max(myUsage + residual * myUsageFraction, 0);
+ // If the calculated rate ends up being 0, set it to 0. rate value of
0 or less is assumed to mean that
Review comment:
It isn't clear why 0 is assumed to mean "no rate limiter is set", if
negative values also connote the same thing. It is conceivable that a rate
limiter could be set, and the rate would be set to 0, right?
--
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]