@terascope/core-utils / promises / PRetryConfig
Interface: PRetryConfig
Defined in: core-utils/src/promises.ts:67
Properties
| Property | Type | Description | Defined in |
|---|---|---|---|
backoff | number | The backoff multiplier Default 2 | core-utils/src/promises.ts:95 |
delay | number | The initial time to delay before retrying the function Default 500 | core-utils/src/promises.ts:81 |
endWithFatal | boolean | If set to true, this will set fail with fatalError to true | core-utils/src/promises.ts:100 |
logError | (...args) => void | Log function for logging any errors that occurred | core-utils/src/promises.ts:110 |
matches? | (string | RegExp)[] | Generally all errors will be treated as retryable, but if you want to limit which errors are retryable you can provide an array of strings or regex patterns to match against the error message and only those that match are considered retryable | core-utils/src/promises.ts:118 |
maxDelay | number | The maximum time to delay when retrying in milliseconds Default 60000 | core-utils/src/promises.ts:88 |
reason? | string | You may set a custom error message if the pRetry fails | core-utils/src/promises.ts:105 |
retries | number | The number of retries to attempt before failing. This does not include the initial attempt Default 3 | core-utils/src/promises.ts:74 |