Home / Companies / Ably / Blog / Post Details
Content Deep Dive

Building a distributed rate limiter that scales horizontally

Blog post from Ably

Post Details
Company
Date Published
Author
Simon Woolf
Word Count
2,045
Company Posts That Month
4
Language
English
Hacker News Points
-
Post removed?
No
Summary

The article discusses the development of a horizontally scalable rate limiter for Ably's realtime messaging platform, addressing challenges such as enforcing instantaneous rate limits and maintaining service quality for other customers during sudden traffic surges. The solution involved introducing an account-wide, global, near-instantaneous message rate limit with specific design constraints including guaranteed message delivery, no blind fanout limit, scalability, throughput stability, predictability, and fast reaction time. The final implementation used a probabilistic suppression factor based on the degree by which the account was beyond its limit, combined with a moving average of the rate measured over 24 seconds. Further improvements included tracking the total number of messages that would have been generated had they succeeded, allowing for more accurate calculation of the suppression rate needed to ensure aggregate message rate exactly at the limit and avoid oscillation.

Trends Found in this Post
Trend Post Mentions Total Month Mentions Posts Companies MoM
Real-time 4 305 93 37 +11%
Serverless 1 313 30 14 +198%
Use This Data

Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.