public abstract class AbstractBackoff extends Object implements Backoff
Backoff implementation.| Constructor and Description |
|---|
AbstractBackoff() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract long |
doNextDelayMillis(int numAttemptsSoFar)
Invoked by
nextDelayMillis(int) after numAttemptsSoFar is validated. |
long |
nextDelayMillis(int numAttemptsSoFar)
Returns the number of milliseconds to wait for before attempting a retry.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitas, exponential, exponential, fibonacci, fixed, of, ofDefault, random, random, withJitter, withJitter, withJitter, withMaxAttempts, withoutDelaypublic final long nextDelayMillis(int numAttemptsSoFar)
BackoffnextDelayMillis in interface BackoffnumAttemptsSoFar - the number of attempts made by a client so far, including the first attempt and
its following retries.protected abstract long doNextDelayMillis(int numAttemptsSoFar)
nextDelayMillis(int) after numAttemptsSoFar is validated.Copyright © 2020 LeanCloud. All rights reserved.