SlidingWindow
Sliding window algorithm: allows to start at most rate
operations in the lapse of per
before current time.
Attributes
- Graph
-
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait RateLimiterAlgorithmclass Objecttrait Matchableclass AnyShow all
Members list
Value members
Concrete methods
Acquires permits to execute the operation. This method should block until a permit is available.
Acquires permits to execute the operation. This method should block until a permit is available.
Attributes
Returns the time in nanoseconds that needs to elapse until the next update. It should not modify internal state.
Returns the time in nanoseconds that needs to elapse until the next update. It should not modify internal state.
Attributes
Runs the operation, allowing the algorithm to take into account its duration, if needed.
Runs the operation, allowing the algorithm to take into account its duration, if needed.
Attributes
Tries to acquire permits to execute the operation. This method should not block.
Tries to acquire permits to execute the operation. This method should not block.
Attributes
Updates the internal state of the rate limiter to check whether new operations can be accepted.
Updates the internal state of the rate limiter to check whether new operations can be accepted.
Attributes
Inherited methods
Acquires a permit to execute the operation. This method should block until a permit is available.
Acquires a permit to execute the operation. This method should block until a permit is available.
Attributes
- Inherited from:
- RateLimiterAlgorithm
Attributes
- Inherited from:
- Product
Attributes
- Inherited from:
- Product
Runs the operation, allowing the algorithm to take into account its duration, if needed.
Runs the operation, allowing the algorithm to take into account its duration, if needed.
Attributes
- Inherited from:
- RateLimiterAlgorithm
Tries to acquire a permit to execute the operation. This method should not block.
Tries to acquire a permit to execute the operation. This method should not block.
Attributes
- Inherited from:
- RateLimiterAlgorithm