|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.netflix.curator.retry.RetryNTimes
com.netflix.curator.retry.RetryOneTime
public class RetryOneTime
A retry policy that retries only once
| Constructor Summary | |
|---|---|
RetryOneTime(int sleepMsBetweenRetry)
|
|
| Method Summary | |
|---|---|
boolean |
allowRetry(int retryCount,
long elapsedTimeMs,
RetrySleeper sleeper)
Called when an operation has failed for some reason. |
int |
getN()
|
| Methods inherited from class com.netflix.curator.retry.RetryNTimes |
|---|
getSleepTimeMs |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RetryOneTime(int sleepMsBetweenRetry)
| Method Detail |
|---|
public int getN()
public boolean allowRetry(int retryCount,
long elapsedTimeMs,
RetrySleeper sleeper)
RetryPolicy
allowRetry in interface RetryPolicyretryCount - the number of times retried so far (0 the first time)elapsedTimeMs - the elapsed time in ms since the operation was attemptedsleeper - use this to sleep - DO NOT call Thread.sleep
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||