P

PrepStack

"Case Study: Distributed Rate Limiter"

A rate limiter (a guard that refuses a caller who sends too many requests in a time) protects an API from overload and from one noisy caller. With one server it is a counter. With many servers the hard part is that the count must be shared, and shared fast. This note builds one design from stated assumptions, not "the" answer. The central trade-off: accuracy against speed and availability. After this note you can place the limiter, choose an algorithm, and explain what happens when its store is down.

Topics in this section