public final class Retryer
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static interface |
Retryer.RetryableFunc<R,E extends java.lang.Throwable> |
static interface |
Retryer.RetryableProc<E extends java.lang.Throwable> |
Modifier and Type | Method and Description |
---|---|
static <T extends java.lang.Throwable> |
retry(RetryOptions options,
java.util.Optional<java.time.Duration> expiration,
Retryer.RetryableProc<T> r) |
static <R,T extends java.lang.Throwable> |
retryWithResult(RetryOptions options,
java.util.Optional<java.time.Duration> expiration,
Retryer.RetryableFunc<R,T> r) |
static <R> java.util.concurrent.CompletableFuture<R> |
retryWithResultAsync(RetryOptions options,
java.util.Optional<java.time.Duration> expiration,
java.util.function.Supplier<java.util.concurrent.CompletableFuture<R>> function) |
public static <T extends java.lang.Throwable> void retry(RetryOptions options, java.util.Optional<java.time.Duration> expiration, Retryer.RetryableProc<T> r) throws T extends java.lang.Throwable
T extends java.lang.Throwable
public static <R,T extends java.lang.Throwable> R retryWithResult(RetryOptions options, java.util.Optional<java.time.Duration> expiration, Retryer.RetryableFunc<R,T> r) throws T extends java.lang.Throwable
T extends java.lang.Throwable
public static <R> java.util.concurrent.CompletableFuture<R> retryWithResultAsync(RetryOptions options, java.util.Optional<java.time.Duration> expiration, java.util.function.Supplier<java.util.concurrent.CompletableFuture<R>> function)