The timeout strategy ensures that operations do not execute for longer than a configured duration.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/App-vNext/Polly/llms.txt
Use this file to discover all available pages before exploring further.
TimeoutStrategyOptions
Configures the timeout resilience strategy.Properties
The default timeout duration.
- Must be greater than 10 milliseconds
- Must be less than 24 hours
- Default is 30 seconds
A generator that produces the timeout for a given execution.When
null, the Timeout property value is used instead.Special values:- Return
TimeSpan.Zeroor negative value: Strategy does nothing - Return
Timeout.InfiniteTimeSpan: Disable timeout for the execution
A delegate that is invoked when a timeout occurs.
Extension Methods
Add timeout strategies to a resilience pipeline:OnTimeoutArguments
Arguments passed to theOnTimeout callback.
Usage Example
Dynamic Timeouts
UseTimeoutGenerator for per-execution timeout values: