class
MarkpdfWeb::RateLimiter
- MarkpdfWeb::RateLimiter
- Reference
- Object
Overview
Per-key fixed-window budget, used to keep auto-render-as-you-type from turning one visitor into a render farm. Keys that go quiet are pruned once the table grows past a few hundred entries.
Defined in:
web.crConstructors
Instance Method Summary
- #allow?(key : String) : Bool
-
#retry_after(key : String) : Int32
Seconds until the key's current window resets (0 when allowed).
Constructor Detail
Instance Method Detail
def retry_after(key : String) : Int32
#
Seconds until the key's current window resets (0 when allowed).