Skip to content
WebsiteHosting.com

concept Delivery & performance

Tail-latency amplification in request fan-out

A parallel request that needs every result waits for its slowest call. Its p99 depends not just on how often each call is slow, but on whether those delays happen in the same requests.

Latest recorded source check · P0160

What it means

When a request starts several calls in parallel and needs every result, it finishes when the last call finishes. Its completion time is the maximum of the call times, not their sum. If each call has an independent chance of being slow, adding calls gives one slow result more chances to hold up the request. No individual call has to get slower for the request’s 99th percentile, or p99, to rise.

Try it

Simulation. Start with 10 independent dependencies. Each finishes in 20 ms with 90% probability and in 200 ms otherwise. The request has a 65.13% chance of taking 200 ms, and its p99 is 200 ms.

Tail-latency amplification in request fan-out

Explain how parallel dependencies change end-to-end percentiles

Simulation
Modeled outcome: Risk

The maximum of all completions has a two-point distribution. Dependence determines its probabilities.

Tail-latency amplification in request fan-out: synthetic scenario inputs
Replaces all inputs with the documented starting example and the indicated change. Reset restores the starting example.
Probability of any slow response

Fan-out assumptions

  1. Calls10
  2. Slow probability per call10%
  3. Dependenceindependent
  4. Percentile99
At least one slow response65.13 %
Fast completion20 ms
Slow completion200 ms
Requested quantile200 ms

The probability is rounded for display; the quantile uses the exact modeled probability before rounding. Shared and independent events are distinct assumptions.

Evaluated inputs

Required scenario evidence
provided
Slow completion
200 ms
Fast completion
20 ms
Dependence assumption
independent
Dependencies waited for
10 count
Per-dependency slow probability
10 %
Population quantile
99 %

Identical two-point marginal latencies; wait for every dependency. Compare only independence and perfect shared-event dependence, not arbitrary correlations. Population lower quantile uses exact rational CDF; displayed probability rounded. Not a real service percentile or estimate from samples.

About this model

The controls set only a local, bounded scenario. The computed branch is not a verdict about a live system. Inputs listed as not evaluated did not participate in this branch after validation.

Reset restores the original inputs. It does not change the open or closed state of help or FAQ answers.

  1. Change only Dependence assumption from independent to shared. Now one event makes all 10 calls slow together. The chance of a slow request falls to 10%, but p99 stays at 200 ms.
  2. With shared still selected, change Population quantile from 99% to 90%. The selected time drops to 20 ms. The chance of a slow request is still 10%: you changed which percentile you read, not how the calls behave.
  3. Use Reset to restore the initial 10 independent calls and the 99% quantile.

From call times to request p99

What must be true for the request to finish by 20 ms? Every call must be fast. With 10 independent calls, the chance is 0.9^10 = 0.3486784401, or about 34.87%. The remaining 65.13% of requests have at least one slow call and finish at 200 ms. In general, for n independent calls that each have slow probability p, the chance of at least one slow call is 1 − (1 − p)^n. It is the probabilities you multiply, not the percentiles.

With a perfectly shared slow event, there is nothing to multiply: either all 10 calls are fast or all 10 are slow. Each call still has the same 10% slow probability. What changes is how often those slow calls occur in the same request. Now 90% of requests finish by 20 ms.

To read p99, look for the earliest time by which at least 99% of requests have finished. The probability of finishing by a given time is the cumulative distribution function, or CDF. In the starting case, neither 34.87% fast under independence nor 90% fast under the shared event reaches 99%. At 200 ms, all requests have finished. That is why the two scenarios have the same p99 despite their different chances of being slow.

Equality at the cutoff matters. Suppose instead that each call has just a 1% slow probability. With one call, exactly 99% of requests finish by 20 ms, so p99 is 20 ms. With two independent calls, only 0.99 × 0.99 = 0.9801, or 98.01%, finish by then. Each call’s p99 is still 20 ms, but the request’s p99 is 200 ms. The simulation uses the exact probability for this decision, not the rounded percentage on display.

Use a deliberately small fan-out to see the quantile boundary. With one call, a 5% slow probability and a 95th percentile, exactly 95% of outcomes finish at the fast time, so the model selects the fast time. With two independent calls, the probability of both being fast is 90.25%, and the same percentile falls at the slow time. This comparison uses exact probability for the threshold, not the rounded percentage displayed by the scene.

In practice

Dean and Barroso’s The Tail at Scale describes the motivation for looking at fan-out: one late subtask can delay a response that needs many results. A component average cannot tell you how often that happens. In the 10-call comparison, each dependency averages 38 ms in both scenarios: 90% at 20 ms and 10% at 200 ms. The average says nothing about whether the slow calls arrive together or hold up separate requests.

For a real service, first establish which results the response actually waits for. Then look at end-to-end durations alongside the dependency times for those same requests. That preserves the information about which calls were slow together—information you cannot recover by averaging component p99 values.

The simulation covers only two possible call times and two assumptions: independent delays or one perfectly shared event. It does not infer the dependence in your service. If the required scenario evidence is missing, the result is unknown, not a zero chance of delay. Use the completion rule and the way call times vary together to explain a request’s tail; use observed request durations and a defined percentile method to assess a service latency objective.

Frequently asked questions

Editorial questions based on the listed sources and explicitly labeled local examples.

Does independence always hold?

No; shared services can correlate latency.

Does waiting for first response have the same formula?

No. The lab takes the maximum of all completion times. A first-response rule would instead use a minimum, which has a different distribution.

Is probability a measured percentile?

No. The fixture derives a probability from stipulated per-call outcomes and dependence, then selects one of two times for a requested percentile. It does not estimate a percentile from measured request samples.

Can reducing fan-out help?

In the independent toy distribution, fewer dependencies lower or preserve the probability of at least one slow completion. This is not a universal performance claim.

Sources & model boundaries

Primary references used for this explanation. The interactive example is an educational model, not a live check.

  1. Dean and Barroso: The Tail at Scale

    fan-out. An aggregate request can wait for many subtasks; delayed redundant attempts may reduce waiting for slow components but add work. No universal numeric speedup.

    Checked .

  2. Google SRE: Service level objectives

    A Note on Statistical Fallacies. High latency quantiles describe a different property from average latency. Even with the same per-dependency average, changes in the tail can matter to an aggregate request.

    Checked .

Report an issue. Include the article URL and ID, not passwords or access keys.