UNPKG

1.06 kBTypeScriptView Raw
1import { Options } from 'p-retry';
2/**
3 * Options to create retry policies. Extends from https://github.com/tim-kos/node-retry.
4 */
5export interface RetryOptions extends Options {
6}
7/**
8 * The default retry policy. Retry up to 10 times, over the span of about 30 minutes. It's not exact because
9 * randomization has been added to prevent a stampeding herd problem (if all instances in your application are retrying
10 * a request at the exact same intervals, they are more likely to cause failures for each other).
11 */
12export declare const tenRetriesInAboutThirtyMinutes: RetryOptions;
13/**
14 * Short & sweet, five retries in five minutes and then bail.
15 */
16export declare const fiveRetriesInFiveMinutes: RetryOptions;
17/**
18 * This policy is just to keep the tests running fast.
19 */
20export declare const rapidRetryPolicy: RetryOptions;
21declare const policies: {
22 tenRetriesInAboutThirtyMinutes: RetryOptions;
23 fiveRetriesInFiveMinutes: RetryOptions;
24 rapidRetryPolicy: RetryOptions;
25};
26export default policies;
27//# sourceMappingURL=retry-policies.d.ts.map
\No newline at end of file