RetryConfig constructor
RetryConfig({})
Implementation
RetryConfig({
required this.strategy,
this.maxAttempts = 3,
this.initialDelay,
this.maxDelay,
this.enableJitter = true,
this.jitterFactor = 0.2,
List<int>? retryableStatusCodes,
this.onRetry,
this.retryOnlyNetworkErrors = false,
}) : retryableStatusCodes =
retryableStatusCodes ??
[
408, // Request Timeout
429, // Too Many Requests
500, // Internal Server Error
502, // Bad Gateway
503, // Service Unavailable
504, // Gateway Timeout
];