sleep(limiter): consumes in "delay" mode and sleeps the
delay.
Functions#
__call__#
__call__(*, key, limit, window, algorithm='fixed-window', tokens=1) -> Effect[ConsumeResult, RateLimiterError]| Parameter | Type | Description |
|---|---|---|
key | str | |
limit | float | |
window | DurationInput | |
algorithm | Algorithm = 'fixed-window' | |
tokens | float = 1 |
Returns Effect[ConsumeResult, RateLimiterError]
def __call__(
self,
*,
key: str,
limit: float,
window: DurationInput,
algorithm: Algorithm = "fixed-window",
tokens: float = 1,
) -> Effect[ConsumeResult, RateLimiterError]: ...