public class RetryForever extends Object implements RetryPolicy
| Constructor and Description |
|---|
RetryForever(long intervalMs) |
| Modifier and Type | Method and Description |
|---|---|
long |
getIntervalMillis()
Return current interval of retries
|
long |
nextRetryMs(int retryCount,
long elapsedTimeMs)
Called when an operation is failed for some reason to determine if it should be retried.
|
RetryForever |
withIntervalMs(long ms)
Create new retry policy with specified retry interval
|
public long nextRetryMs(int retryCount,
long elapsedTimeMs)
RetryPolicynextRetryMs in interface RetryPolicyretryCount - the number of times retried so far (0 the first time)elapsedTimeMs - the elapsed time in ms since the operation was attemptedpublic long getIntervalMillis()
public RetryForever withIntervalMs(long ms)
ms - new interval in millisecondsCopyright © 2024. All rights reserved.