Polly
A .NET resilience library for retries, circuit breakers, timeouts and related strategies around unreliable calls.
In more detail
Each strategy is configured with explicit limits, such as a number of attempts or a time budget. Microsoft.Extensions.Http.Resilience builds on it to offer AddStandardResilienceHandler for HttpClient.
Related terms
- resilience — An application's ability to keep working, or fail gracefully, when a dependency is slow or failing.
- retry — Sending a request again after it failed or timed out, in the hope that it succeeds the second time.
- circuit breaker — A wrapper around calls to another service that stops making calls for a while after repeated failures, so the failing service can recover.
- AddStandardResilienceHandler — A one-line setup that adds a recommended resilience pipeline, including rate limiting, total timeout, retry, circuit breaker and attempt timeout, to an HttpClient.
Taught in
- Retry and Circuit Breaker Policies with Polly — Modern .NET Core, C# & Enterprise Microservices