Files
plugins/packages/rate-limit/test
chrnx 66afb59103 feat(rate-limit): sweep expired windows instead of walking the map
hit() called evictExpired on every new or expired key, which is a full walk of
the map — O(N^2) over N callers, and a client rotating addresses drives it on
purpose. A timer armed on the first hit does the same work off the hot path.

It is not unref'ed, deliberately: the timer holds the process open so that
failing to release it fails the exit test rather than leaking quietly.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-09-18 13:18:26 -05:00
..