Loading…
While this loads — quick one
Every subscriber must get each event. A queue, or pub/sub?
Loading…
While this loads — quick one
Every subscriber must get each event. A queue, or pub/sub?
Loading the challenge…
While this loads — quick one
Every subscriber must get each event. A queue, or pub/sub?
A public API is being abused: a few clients fire thousands of requests a second and starve everyone else. The team wants to cap each client to a fixed number of requests per time window and reject the rest immediately, before any real work is done. The check has to be cheap, because it runs on every single request, and it has to be consistent across a fleet of identical API servers behind a load balancer, so a client cannot slip past simply by being routed to a different server each time. The limits themselves change rarely.
Every system design question opens with an account. Your design is scored the same way every time, with the reason behind each requirement, and your attempts are kept so you can see what you found hard.