ConnectionLostRetryPolicy
open class ConnectionLostRetryPolicy : RetryPolicy, @unchecked Sendable
A retry policy that automatically retries idempotent requests for network connection lost errors. For more information about retrying network connection lost errors, please refer to Apple’s technical document.
-
Creates a
ConnectionLostRetryPolicyinstance from the specified parameters.Declaration
Swift
public init(retryLimit: UInt = RetryPolicy.defaultRetryLimit, exponentialBackoffBase: UInt = RetryPolicy.defaultExponentialBackoffBase, exponentialBackoffScale: Double = RetryPolicy.defaultExponentialBackoffScale, retryableHTTPMethods: Set<HTTPMethod> = RetryPolicy.defaultRetryableHTTPMethods)Parameters
retryLimitThe total number of times the request is allowed to be retried.
RetryPolicy.defaultRetryLimitby default.exponentialBackoffBaseThe base of the exponential backoff policy.
RetryPolicy.defaultExponentialBackoffBaseby default.exponentialBackoffScaleThe scale of the exponential backoff.
RetryPolicy.defaultExponentialBackoffScaleby default.retryableHTTPMethodsThe idempotent http methods to retry.
RetryPolicy.defaultRetryableHTTPMethodsby default.
View on GitHub
Install in Dash