@NotThreadSafe
public class RetryBoundedBackOff
extends java.lang.Object
implements com.google.api.client.util.BackOff
BackOff that limits the number of calls on another BackOff.
This class will call the same methods of another BackOff until the maximum number of
retries are reached, and then it will return BackOff.STOP.| Constructor and Description |
|---|
RetryBoundedBackOff(int maxRetries,
com.google.api.client.util.BackOff backoff)
RetryBoundedBackOff takes a
BackOff and limits the retries. |
| Modifier and Type | Method and Description |
|---|---|
long |
nextBackOffMillis() |
void |
reset() |
public RetryBoundedBackOff(int maxRetries,
com.google.api.client.util.BackOff backoff)
BackOff and limits the retries.maxRetries - Number of retries to attempt. Must be greater or equal to 0.backoff - The underlying BackOff to use.public void reset()
throws java.io.IOException
reset in interface com.google.api.client.util.BackOffjava.io.IOExceptionpublic long nextBackOffMillis()
throws java.io.IOException
nextBackOffMillis in interface com.google.api.client.util.BackOffjava.io.IOExceptionCopyright © 2019. All rights reserved.