| 程序包 | 说明 |
|---|---|
| cn.aotcloud.retry |
| 限定符和类型 | 方法和说明 |
|---|---|
static <V> RetryerBuilder<V> |
RetryerBuilder.newBuilder()
Constructs a new builder
|
RetryerBuilder<V> |
RetryerBuilder.retryIfException()
Configures the retryer to retry if an exception (i.e. any
Exception or subclass
of Exception) is thrown by the call. |
RetryerBuilder<V> |
RetryerBuilder.retryIfException(com.google.common.base.Predicate<Throwable> exceptionPredicate)
Configures the retryer to retry if an exception satisfying the given predicate is
thrown by the call.
|
RetryerBuilder<V> |
RetryerBuilder.retryIfExceptionOfType(Class<? extends Throwable> exceptionClass)
Configures the retryer to retry if an exception of the given class (or subclass of the given class) is
thrown by the call.
|
RetryerBuilder<V> |
RetryerBuilder.retryIfResult(com.google.common.base.Predicate<V> resultPredicate)
Configures the retryer to retry if the result satisfies the given predicate.
|
RetryerBuilder<V> |
RetryerBuilder.retryIfRuntimeException()
Configures the retryer to retry if a runtime exception (i.e. any
RuntimeException or subclass
of RuntimeException) is thrown by the call. |
RetryerBuilder<V> |
RetryerBuilder.withAttemptTimeLimiter(AttemptTimeLimiter<V> attemptTimeLimiter)
Configures the retryer to limit the duration of any particular attempt by the given duration.
|
RetryerBuilder<V> |
RetryerBuilder.withBlockStrategy(BlockStrategy blockStrategy)
Sets the block strategy used to decide how to block between retry attempts.
|
RetryerBuilder<V> |
RetryerBuilder.withRetryListener(RetryListener listener)
Adds a listener that will be notified of each attempt that is made
|
RetryerBuilder<V> |
RetryerBuilder.withStopStrategy(StopStrategy stopStrategy)
Sets the stop strategy used to decide when to stop retrying.
|
RetryerBuilder<V> |
RetryerBuilder.withWaitStrategy(WaitStrategy waitStrategy)
Sets the wait strategy used to decide how long to sleep between failed attempts.
|
Copyright © 2023. All rights reserved.