Broken at ScaleHow big systems break

Free tool

Latency Budget Calculator

List the hops a request makes, in order. See where the milliseconds go on a normal day, on a slow day, and when a hop is down and every retry runs to its timeout.

Your request path

Hop p50 ms p99 ms Timeout ms Retries Calls next Remove

The starting numbers are an example path, not measurements of any real system. Put in your own.

Where the time goes

Typicalsum of the p50s
Slow dayevery hop at its p99
Everything downevery retry to its timeout
Retry storm

What a latency budget is

A latency budget is the time a request may take, end to end, before it's too slow to matter: a page that feels instant, an API call inside its caller's own timeout. Every hop the request makes spends part of it. Adding the hops up shows which one spends the most, and whether the rest have room to absorb a bad day.

Why the p99 line matters more than the typical one

The typical total (the p50s added up) is what you see when you test it yourself. Users who hit a slow hop see something closer to the slow-day line. A path with many hops almost always has one of them slow, so the slow-day total is a better guide to what your slowest users feel. Adding p99s together is pessimistic: it's the bound, not the percentile.

Timeouts longer than the budget

If one attempt at a hop can wait longer than your whole budget, the user is gone before your code gives up. A timeout should be shorter than what's left of the budget when the call starts, so the caller still has time to try something else or fail fast.

How retries multiply

A retry is cheap for one request and expensive for all of them. When a service calls another, and each one retries the one below it, the attempts multiply down the chain. Three retries at the app and three at the database means up to 16 database attempts for one user click, all landing on the database exactly when it is struggling. That's a retry storm. The "Retry storm" number above is that product for your path.

How to win the budget back