Delay Module
The backoff calculation used by the retrying effects in Orsak.Resilience: an exponentially growing delay,
with random jitter, based on Polly's "decorrelated jitter backoff V2".
Functions and values
| Function or value |
Description
|
Full Usage:
ExponentialFactor
Returns: float
|
The base of the exponential growth of the delay.
|
Full Usage:
Pfactor
Returns: float
|
A factor that dampens the growth of the first few delays.
|
Full Usage:
RpScalingFactor
Returns: float
|
Scales the delay, so that the median of the first delay is the base delay.
|
Full Usage:
calculateDelayWithJitter attempt prev baseDelay randomizer
Parameters:
int64
-
The number of the attempt, from 0
prev : byref<float>
-
The state of the calculation between attempts, updated by the call; start with 0
baseDelay : TimeSpan
-
The median of the first delay
randomizer : IRandomGenerator
-
The source of the jitter
Returns: TimeSpan
|
The delay before retry attempt, with jitter.
|
Full Usage:
getDelay attempt prev baseDelay maxDelay randomizer
Parameters:
int64
-
The number of the attempt, from 0
prev : byref<float>
-
The state of the calculation between attempts, updated by the call; start with 0
baseDelay : TimeSpan
-
The median of the first delay
maxDelay : Nullable<TimeSpan>
-
The longest delay, or no limit
randomizer : IRandomGenerator
-
The source of the jitter
Returns: TimeSpan
|
The delay before retry attempt, with jitter, capped at maxDelay.
|
Orsak