public interface StopStrategy
Modifier and Type | Method and Description |
---|---|
boolean |
shouldStop(int previousAttemptNumber,
long delaySinceFirstAttemptInMillis)
Returns
true if the retryer should stop retrying. |
boolean shouldStop(int previousAttemptNumber, long delaySinceFirstAttemptInMillis)
true
if the retryer should stop retrying.previousAttemptNumber
- the number of the previous attempt (starting from 1)delaySinceFirstAttemptInMillis
- the delay since the start of the first attempt,
in millisecondstrue
if the retryer must stop, false
otherwise