Design Rate Limiter
Programming Interview
Medium
4 views
Problem Description
Design a rate limiter for an API gateway.
Official Solution
Pick a policy (token bucket is common). Keep per-key counters in Redis with TTL, or use a fixed-window + sliding correction. Enforce at the edge (gateway) and include response headers (limit, remaining, reset). Handle bursts, distributed nodes, and clock skew.
Solutions (0)
No solutions submitted yet. Be the first!
No comments yet. Start the discussion!