I know I can specify the list of HTTP error codes (e.g. 408, 502, 503, etc. ) I would like to get retried using Polly, but what is the list of these codes that would be retried by default if none is specified?
What is the list of [Http status] codes that would be retried by default [by Polly] if none is specified?
Polly on its own contains no in-built definitions of what it retries: you as the user specify that when defining a policy.
Polly with HttpClientFactory (using services.AddHttpClient(...).AddTransientHttpErrorPolicy(...)
in StartUp
in .Net Core) retries the following items, per the Polly with HttpClientFactory documentation:
This should also be shown in the intellisense when you hover over the method.
The .HandleTransientHttpError()
method available via the Polly.Extensions.Http
package also handles the same set of exceptions and status codes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With