Live data from Hacker News

An Interactive Guide to Rate Limiting

blog.sagyamthapa.com.np

1–10 of 48 posts

Re: An Interactive Guide to Rate Limiting

#3
I wonder if anyone has switched algorithms after hitting real-world scaling issues with one of those? Curious if there are any “gotchas” that only show up at scale. I only have experience with fixed window rate limiting

Re: An Interactive Guide to Rate Limiting

#9
post #3

I wonder if anyone has switched algorithms after hitting real-world scaling issues with one of those? Curious if there are any “gotchas” that only show up at scale. I only have experience with fixed window rate limiting

We used a token bucket one to allow say 100 requests immediately but the limit would actually replenish 10 per minute or something. Makes sense to allow bursts. This was to allow free tier users to test things. Unless they go crazy, they would not even notice a rate limiter.

Sliding window might work good with large intervals. If you have something like a 24h window, fixed window will abruply cut things off for hours.

I mostly work with 1 minute windows so its fixed all the way.

Re: An Interactive Guide to Rate Limiting

#10

Excellent dataviz. Related tangent, "HPBN" (High-Performance Browser Networking) is a great book that includes related concepts. https://hpbn.co/

Seconded, this book goes hand-in-hand with "Designing Data-Intensive Applications" by Martin Kleppmann [0].

[0](https://www.oreilly.com/library/view/designing-data-intensiv...)

Post reply on HN