reactor.util.retry.RetrySpec
and reactor.util.retry.RetryBackoffSpec
instead.@Deprecated public class DefaultRetry<T> extends AbstractRetry<T,Throwable> implements Retry<T>
Modifier and Type | Method and Description |
---|---|
org.reactivestreams.Publisher<Long> |
apply(reactor.core.publisher.Flux<Throwable> errors)
Deprecated.
|
Retry<T> |
backoff(Backoff backoff)
Deprecated.
Returns a retry function with backoff delay.
|
static <T> DefaultRetry<T> |
create(Predicate<? super RetryContext<T>> retryPredicate)
Deprecated.
|
Retry<T> |
doOnRetry(Consumer<? super RetryContext<T>> onRetry)
Deprecated.
Returns a retry function that invokes the provided onRetry
callback before every retry.
|
Retry<T> |
jitter(Jitter jitter)
Deprecated.
Returns a retry function that applies jitter to the backoff delay.
|
Retry<T> |
retryMax(long maxIterations)
Deprecated.
Retry function that retries n times.
|
Retry<T> |
timeout(Duration timeout)
Deprecated.
Returns a retry function with timeout.
|
String |
toString()
Deprecated.
|
Retry<T> |
withApplicationContext(T applicationContext)
Deprecated.
Returns a retry function with an application context that may be
used to perform any rollbacks before a retry.
|
Retry<T> |
withBackoffScheduler(reactor.core.scheduler.Scheduler scheduler)
Deprecated.
Returns a retry function that uses the scheduler provided for
backoff delays.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
allBut, any, anyOf, apply, exponentialBackoff, exponentialBackoffWithJitter, fixedBackoff, noBackoff, onlyIf, randomBackoff, retryOnce
public static <T> DefaultRetry<T> create(Predicate<? super RetryContext<T>> retryPredicate)
public Retry<T> withApplicationContext(T applicationContext)
Retry
Retry.onlyIf(Predicate)
,
custom backoff function Retry.backoff(Backoff)
and retry
callback Retry.doOnRetry(Consumer)
. All other properties of
this retry function are retained in the returned instance.withApplicationContext
in interface Retry<T>
applicationContext
- Application contextpublic Retry<T> doOnRetry(Consumer<? super RetryContext<T>> onRetry)
Retry
RetryContext
provided
to the callback contains the iteration and the any application
context set using Retry.withApplicationContext(Object)
.
All other properties of this retry function are retained in the
returned instance.public Retry<T> retryMax(long maxIterations)
Retry
public Retry<T> timeout(Duration timeout)
Retry
public Retry<T> backoff(Backoff backoff)
Retry
public Retry<T> jitter(Jitter jitter)
Retry
public Retry<T> withBackoffScheduler(reactor.core.scheduler.Scheduler scheduler)
Retry
withBackoffScheduler
in interface Retry<T>
scheduler
- the scheduler for backoff delayspublic org.reactivestreams.Publisher<Long> apply(reactor.core.publisher.Flux<Throwable> errors)