public interface RateLimiterEndpoint extends LimiterEndpoint
A limiter endpoint that can be (administratively) connected to a Rate Limiter or a Queue Saturation Limiter.
LimiterEndpoint
Modifier and Type | Method and Description |
---|---|
void |
forceUseUnit()
Consumes one unit of work.
|
void |
forceUseUnits(int units)
Consumes the given number of units of work.
|
boolean |
useUnit()
Requests one unit of work.
|
boolean |
useUnits(int units)
Requests the given number of units of work.
|
boolean useUnit()
Requests one unit of work. Returns true if the work is allowed, false otherwise. Equivalent to useUnits(1).
boolean useUnits(int units)
Requests the given number of units of work. Returns true if the work is allowed, false otherwise.
void forceUseUnit()
Consumes one unit of work. Equivalent to forceUseUnits(1).
void forceUseUnits(int units)
Consumes the given number of units of work.