Sliding window rate limiter

The core idea

A sliding-window limiter checks how much a caller has been admitted during the most recent period.

The window moves with each decision.

In this lesson

  • What belongs inside the window
  • Try the expiry boundary
  • Make the decision atomic
  • Compressing the history into seconds
  • Redis and the response contract

Continue reading

Pro unlocks video lessons, visual walkthroughs, full notes, diagrams, case studies, and implementations across the System Design archive.