Represents an implementation of a retry policy. For each time the messaging operation must be retried, the delay between retries grows in a staggered, exponential manner.
Assembly: Microsoft.ServiceBus (in Microsoft.ServiceBus.dll)
Thetype exposes the following members.
|RetryExponential(TimeSpan, TimeSpan, Int32)||Initializes a new instance of the class.|
|RetryExponential(TimeSpan, TimeSpan, TimeSpan, TimeSpan, Int32)||Obsolete. Initializes a new instance of the class.|
|DeltaBackoff||Gets or sets the backoff interval associated with the retry.|
|MaximumBackoff||Gets or sets the maximum backoff interval.|
|MaxRetryCount||Gets or sets the maximum number of allowed retries.|
|MinimalBackoff||Gets or sets the minimum backoff interval.|
|TerminationTimeBuffer||Gets or sets the termination time buffer associated with the retry.|
The retry policy has the following characteristics:
The policy always honors the OperationTimeout value, so that the retry operation terminates if the next retry interval exceeds the operation time.
The policy only retries when the IsTransient property is true.
The policy should delay an additional 10 seconds if the exception is ServerBusyException.
The retry policy calculation is performed up to the MaxRetryCount property value, and each calculation follows a staggered exponential curve.
If possible, you should change the OperationTimeout value to control how long each retry should wait, rather than supplying a custom policy instance. The default policy RetryPolicy.Default already uses a instance with a reasonable default value that interacts with the operation timeout value.