RetryPolicy
RetryPolicy<
E> =object
Defined in: Types/RetryPolicy.ts:34
An immutable policy describing retry limits, backoff delay strategies, transient failure filters, and observational telemetry.
Example
Section titled “Example”Type Parameters
Section titled “Type Parameters”E = unknown
Properties
Section titled “Properties”attempts
Section titled “attempts”
readonlyattempts:number
Defined in: Types/RetryPolicy.ts:35
getDelay
Section titled “getDelay”
readonlygetDelay: (attempt) =>Duration
Defined in: Types/RetryPolicy.ts:36
Parameters
Section titled “Parameters”attempt
Section titled “attempt”number
Returns
Section titled “Returns”onRetry?
Section titled “onRetry?”
readonlyoptionalonRetry?: (event) =>void
Defined in: Types/RetryPolicy.ts:38
Parameters
Section titled “Parameters”RetryEvent<E>
Returns
Section titled “Returns”void
readonlyoptionalwhen?: (error) =>boolean
Defined in: Types/RetryPolicy.ts:37
Parameters
Section titled “Parameters”E
Returns
Section titled “Returns”boolean