Documentation / @zerotal/client / index / RetryOptions
Interface: RetryOptions
Defined in: client/src/http.ts:110
Properties
attempts?
optionalattempts?:number
Defined in: client/src/http.ts:112
Max retry attempts after the first try. Default: 2.
methods?
optionalmethods?:string[]
Defined in: client/src/http.ts:114
HTTP methods eligible for retry. Default: idempotent verbs (GET/PUT/DELETE/HEAD/OPTIONS).
statuses?
optionalstatuses?:number[]
Defined in: client/src/http.ts:116
HTTP statuses that should be retried. Default: 408, 425, 429, 500, 502, 503, 504.
respectRetryAfter?
optionalrespectRetryAfter?:boolean
Defined in: client/src/http.ts:118
Honor a Retry-After header when present. Default: true.
backoff?
optionalbackoff?: (attempt,retryAfterMs) =>number
Defined in: client/src/http.ts:120
Compute the delay (ms) before attempt N. Default: exponential backoff + jitter.
Parameters
attempt
number
retryAfterMs
number | null
Returns
number