public class RetryWithExponentialBackOff extends RetryPolicy
RetryPolicy.RetryCancelled| Modifier and Type | Field and Description |
|---|---|
static RetryWithExponentialBackOff |
DEFAULT |
startRetryTime| Constructor and Description |
|---|
RetryWithExponentialBackOff(int startMsBeforeRetry)
Constructor
|
RetryWithExponentialBackOff(int startMsBeforeRetry,
int maxRetryCount,
int maxDelay)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
shouldRetry(ConnectionState state)
Should another retry be attempted according to the policy
|
retrypublic static final RetryWithExponentialBackOff DEFAULT
public RetryWithExponentialBackOff(int startMsBeforeRetry)
startMsBeforeRetry - milliseconds before retrying base timepublic RetryWithExponentialBackOff(int startMsBeforeRetry,
int maxRetryCount,
int maxDelay)
startMsBeforeRetry - milliseconds before retrying base timemaxRetryCount - max retry countmaxDelay - max delay between retriespublic boolean shouldRetry(ConnectionState state)
RetryPolicyshouldRetry in class RetryPolicystate - current connection state