Class RetryPolicy
-
- All Implemented Interfaces:
public final class RetryPolicyData class representing the retry policy configuration for an HTTP request.
-
-
Field Summary
Fields Modifier and Type Field Description private Set<Integer>retryableStatusCodesprivate final IntegermaxRetriesprivate final LongretryIntervalprivate final DoubledelayFactor
-
Constructor Summary
Constructors Constructor Description RetryPolicy(Integer maxRetries, Long retryInterval, Double delayFactor)
-
Method Summary
Modifier and Type Method Description final Set<Integer>getRetryableStatusCodes()final UnitsetRetryableStatusCodes(Set<Integer> retryableStatusCodes)final IntegergetMaxRetries()The maximum number of retries allowed for the request. final LonggetRetryInterval()The interval between retries in milliseconds. final DoublegetDelayFactor()The delay factor applied to the retry interval for exponential backoff. -
-
Method Detail
-
getRetryableStatusCodes
final Set<Integer> getRetryableStatusCodes()
-
setRetryableStatusCodes
final Unit setRetryableStatusCodes(Set<Integer> retryableStatusCodes)
-
getMaxRetries
final Integer getMaxRetries()
The maximum number of retries allowed for the request.
-
getRetryInterval
final Long getRetryInterval()
The interval between retries in milliseconds.
-
getDelayFactor
final Double getDelayFactor()
The delay factor applied to the retry interval for exponential backoff. Defaults to 1.0 if not specified.
-
-
-
-