public class ExponentialBackOffIntervalRetryScheduler extends AbstractRetryScheduler
| Modifier and Type | Class and Description |
|---|---|
static class |
ExponentialBackOffIntervalRetryScheduler.Builder
Builder class to instantiate an
ExponentialBackOffIntervalRetryScheduler. |
| Modifier | Constructor and Description |
|---|---|
protected |
ExponentialBackOffIntervalRetryScheduler(ExponentialBackOffIntervalRetryScheduler.Builder builder)
Instantiate an
ExponentialBackOffIntervalRetryScheduler. |
| Modifier and Type | Method and Description |
|---|---|
static ExponentialBackOffIntervalRetryScheduler.Builder |
builder()
Instantiate a Builder to be able to create a
ExponentialBackOffIntervalRetryScheduler. |
protected long |
computeRetryInterval(CommandMessage commandMessage,
RuntimeException lastFailure,
List<Class<? extends Throwable>[]> failures)
Compute the amount of milliseconds delay until the next retry, given the information passed.
|
isExplicitlyNonTransient, scheduleRetry, scheduleRetryprotected ExponentialBackOffIntervalRetryScheduler(ExponentialBackOffIntervalRetryScheduler.Builder builder)
ExponentialBackOffIntervalRetryScheduler. the settings are copied from the
ExponentialBackOffIntervalRetryScheduler.Builder and validated.builder - public static ExponentialBackOffIntervalRetryScheduler.Builder builder()
ExponentialBackOffIntervalRetryScheduler.
The default for maxRetryCount is set to a single retry, the backoffFactor defaults to 100ms
and the nonTransientFailurePredicate defaults to AxonNonTransientExceptionClassesPredicate.
The ScheduledExecutorService is a hard requirement and as such should be provided.
ExponentialBackOffIntervalRetrySchedulerprotected long computeRetryInterval(CommandMessage commandMessage, RuntimeException lastFailure, List<Class<? extends Throwable>[]> failures)
AbstractRetrySchedulercomputeRetryInterval in class AbstractRetrySchedulercommandMessage - the command that was sent (and failed).lastFailure - the last failure that caused this retry scheduler to be called.failures - a List of all failures up to now.Copyright © 2010–2023. All rights reserved.