liubao68 commented on code in PR #3278:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/3278#discussion_r943122755


##########
handlers/handler-flowcontrol-qps/src/main/java/org/apache/servicecomb/qps/strategy/LeakyBucketStrategy.java:
##########
@@ -47,7 +47,7 @@ public boolean isLimitNewRequest() {
       throw new IllegalStateException("should not happen");
     }
     if (this.getBucketLimit() == null) {
-      this.setBucketLimit(Math.max(2 * this.getQpsLimit(), Integer.MAX_VALUE));
+      this.setBucketLimit(Math.min(2 * this.getQpsLimit(), Integer.MAX_VALUE));

Review Comment:
   Seems all of the two are not correct. The first result is 
`Integer.MAX_VALUE`, the second is `2 * this.getQpsLimit()`



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