public class Retry extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
Retry.BuilderDone |
static interface |
Retry.NeedsLogInterval |
static interface |
Retry.NeedsMaxWait |
static interface |
Retry.NeedsRetries |
static interface |
Retry.NeedsRetryDelay |
static interface |
Retry.NeedsTimeIncrement |
static interface |
Retry.RetryFactory |
Modifier and Type | Method and Description |
---|---|
static Retry.NeedsRetries |
builder() |
boolean |
canRetry() |
long |
getLogInterval() |
boolean |
hasInfiniteRetries() |
boolean |
hasRetried() |
void |
logRetry(org.slf4j.Logger log,
String message) |
void |
logRetry(org.slf4j.Logger log,
String message,
Throwable t) |
long |
retriesCompleted() |
protected void |
sleep(long wait) |
void |
useRetry() |
void |
waitForNextAttempt() |
public boolean hasInfiniteRetries()
public long getLogInterval()
public boolean canRetry()
public void useRetry()
public boolean hasRetried()
public long retriesCompleted()
public void waitForNextAttempt() throws InterruptedException
InterruptedException
protected void sleep(long wait) throws InterruptedException
InterruptedException
public void logRetry(org.slf4j.Logger log, String message)
public static Retry.NeedsRetries builder()
Copyright © 2011–2019 The Apache Software Foundation. All rights reserved.