Skip to content

Commit

Permalink
Update PipeEndPointRateLimiter.java
Browse files Browse the repository at this point in the history
  • Loading branch information
SteveYurongSu committed May 24, 2024
1 parent 22d2af1 commit 8484c92
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,8 @@ public class PipeEndPointRateLimiter {

private final RateLimiter rateLimiter = RateLimiter.create(Double.MAX_VALUE);

public PipeEndPointRateLimiter(double transferDataSizeBytesPerSecond) {
rateLimiter.setRate(
transferDataSizeBytesPerSecond <= 0 ? Double.MAX_VALUE : transferDataSizeBytesPerSecond);
public PipeEndPointRateLimiter(double bytesPerSecond) {
rateLimiter.setRate(bytesPerSecond <= 0 ? Double.MAX_VALUE : bytesPerSecond);
}

public void acquire(long bytes) {
Expand Down

0 comments on commit 8484c92

Please sign in to comment.