How Retry Storms Crash C# Services and Why Exponential Backoff with Jitter Fixes It
When a backend service briefly fails, naive retry loops in client code can trigger a 'retry storm,' where thousands of clients bombard the server simultaneously and prevent recovery even after the original fault clears. A four-second database blip in one documented scenario stretched into a forty-minute outage because 5,000 clients were firing millions of requests per second at a service already under strain. Simple fixed-delay retries reduce request rate but still synchronize clients to retry at the same instant, leaving peak concurrency — the metric that crashes connection pools — unchanged. Exponential backoff addresses this by progressively lengthening wait times between attempts, while adding random jitter spreads retries across the full interval so no two clients hit the server at the same moment. Together, these techniques in C#'s HttpClient implementations allow struggling services to drain their backlog and recover rather than being pinned in a failed state by the very clients trying to reach them.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.


Discussion (0)
Log in to join the discussion and vote.
Log in