What a deadline bounds that an attempt count cannot, and why only the caller knows whether an answer is still wanted.
3 May 2027
An attempt count bounds how many times you try. A deadline bounds when you stop, and only one of the two has anything to do with the person waiting. Propagating a deadline means passing down the absolute time it expires rather than a fresh duration, so a call entered with 300 ms left runs for 300 ms instead of starting another thirty-second clock. gRPC and Go’s context.Context do this by default; most HTTP clients do not. The deliberate consequence is cancelling work that was about to finish: a deadline set too tight kills requests the user would have waited for, and there is no version of the bound that avoids that.
Outline#
- what a deadline bounds that an attempt count does not
- propagating the time remaining instead of starting a fresh timeout
- cancelling work that was about to succeed, on purpose
Teaching team
- Marisol Quaye — convenor
