Skip to main content

Module rate_limit

Module rate_limit 

Source
Expand description

Fixed-window rate limiting (Rails 8 rate_limit to:, within:), backed by any doido_cache::CacheStore.

Each key counts requests within a window; the stored entry carries the window start, so the window resets correctly regardless of the cache’s TTL support.

Structs§

RateLimiter
Allow at most limit requests per window_secs per key.