Skip to content
0:00 / 0:00

#ratelimiting#capacitymanagement#little'slaw

"Stop Rate Limiting! Capacity Management Done Right" by Jon Moore

Strange Loop Conference

88K subscribers • 107 videos on Hallway • Conference channel

YouTube
  • Recommended by 5 people: 4 on Hacker News and 1 on Lobsters.
  • A classic. People kept recommending it from 2017 to 2024.
  • Presented by Jon Moore, Chief Software Architect at Comcast Cable
  • An opinion. It argues one side of a question engineers disagree on.

Intermediate. Assumes working knowledge.

41K views9 years ago5 recommendations

Distributed systemsSystems programmingConcurrency and parallelismScaling and large-scale architectureSoftware architecture

Jon Moore explains why rate limiting is the wrong abstraction for protecting microservices and argues for concurrency-based capacity management using Little's Law.

In an era of cloud computing and microservices, it's imperative to be able to isolate clients from one another in terms of the resources they can use--otherwise, one misconfigured or malicious client can make a service unusable for everyone else. Steve Yegge mentions quotas and throttling as key practices in his notorious "platform rant." If you've ever had one of your internal microservices launch an unintentional denial of service attack against another one, this talk is for you! The most common mechanism available in both open source and commercial API gateways is rate limiting: making sure a particular clients sends no more than a certain number of requests per unit time. As it turns out, this is exactly the wrong abstraction for multiple reasons. In this talk, we'll learn about a particularly powerful concept from queuing theory known as Little's Law and use it to understand where rate limiting can break down and why an alternative--concurrency control--can be a superior way of addressing this problem. This leads to an elegant implementation that's still easy for clients to understand. Next, we'll talk about an extension to the basic implementation that permits decentralized enforcement and an adaptive, optimistic algorithm that works well with a constantly changing mix of elastic origin capacity, population of clients, and fluctuating usage. A must-have part of your service's self-defense kit! Jon Moore COMCAST Jon Moore is the Chief Software Architect at Comcast Cable, where he focuses on delivering a core set of scalable, performant, robust software components for the company's varied software product development groups. He specializes in the "art of the possible," finding ways to coordinate working solutions for complex problems and deliver them on time (even in large enterprises). Jon is equally comfortable leading and managing teams and personally writing production-ready code. Jon has a passion for software engineering, continuously learning and then teaching colleagues new ways to deliver working, maintainable software with ever-higher quality and ever-shorter delivery times. His current interests include distributed systems, fault tolerance, building healthy and engaging engineering cultures, and Texas Hold'em. Jon received his Ph.D. in Computer and Information Science from the University of Pennsylvania and currently resides in West Philadelphia, although he was neither born there nor raised there and does not spend most of his days on playgrounds.

Why it's here

5 people recommend this

What people say. Recommended as the clearest explanation of why concurrency limiting is superior to rate limiting for protecting services from noisy clients.

luckystarron Hacker News • Recommends

On “How to Design a Scalable Rate Limiting Algorithm”

For a different view on the topic watch "Stop Rate Limiting! Capacity Management Done Right" link to this video The basic premise is not do do req/s limiting but rather concurrency limiting which results in req/s limiting by itself. Concurrency limiting is rather simple and doesn't require a lot of code complexity.

cpetersoon Hacker News • Recommends

On “Ask HN: What’s your favorite talk from 2017?”

…ools to the predominately African American community in upper Manhattan. link * Stop Rate Limiting! Capacity Management Done Right. Jon Moore is the Chief Software Architect at Comcast Cable, where he focuses on delivering a core set of scalable, performant, robust software components for the company's varied software product development groups. link to this video * Keeping Time in Real Systems. This talk will tour the fascinating timekeeping mechanisms used in real systems. We will explore atomic clocks, NTP and GPS through systems that use them, and logical clocks in the context of systems built on logical time. link * Level Up Your Concurrency Skills With Rust. This talk will show you how Rust w…

oftenwrongon Hacker News • Recommends

On “It’s Time for Some Queueing Theory”

Relevant to queueing theory: "Stop Rate Limiting! Capacity Management Done Right" by Jon Moore link to this video

Lanzaaon Hacker News • Recommends

On “Amazon S3 Adds Put-If-Match (Compare-and-Swap)”

You will like the Strange Loop 2017 talk about this subject: "Stop Rate Limiting! Capacity Management Done Right" by Jon Moore link to this video Concurrent capacity might not be the best metric.

gregnavison Lobsters • Recommends

Jon Moore StrangeLoop 2017 Talk: Stop Rate Limiting! Capacity Management Done Right