Package | Description |
---|---|
dev.failsafe |
APIs for performing failsafe executions.
|
Modifier and Type | Method and Description |
---|---|
CheckedFunction<ExecutionAttemptedEvent<R>,R> |
FallbackConfig.getFallback()
Returns the fallback function, else
null if a fallback stage function was configured instead. |
CheckedFunction<ExecutionAttemptedEvent<R>,CompletableFuture<R>> |
FallbackConfig.getFallbackStage()
Returns the fallback stage function, else
null if a fallback function was configured instead. |
Modifier and Type | Method and Description |
---|---|
static <R> FallbackBuilder<R> |
Fallback.builder(CheckedFunction<ExecutionAttemptedEvent<? extends R>,? extends R> fallback)
Returns the
fallback to be executed if execution fails. |
static <R> FallbackBuilder<R> |
Fallback.builderOfException(CheckedFunction<ExecutionAttemptedEvent<? extends R>,? extends Exception> fallback)
Returns the
fallback to be executed if execution fails and allows an alternative exception to be supplied
instead. |
static <R> FallbackBuilder<R> |
Fallback.builderOfStage(CheckedFunction<ExecutionAttemptedEvent<? extends R>,? extends CompletionStage<R>> fallback)
Returns the
fallback to be executed if execution fails. |
static <R> Fallback<R> |
Fallback.of(CheckedFunction<ExecutionAttemptedEvent<? extends R>,? extends R> fallback)
Returns the
fallback to be executed if execution fails. |
static <R> Fallback<R> |
Fallback.ofException(CheckedFunction<ExecutionAttemptedEvent<? extends R>,? extends Exception> fallback)
Returns the
fallback to be executed if execution fails and allows an alternative exception to be supplied
instead. |
static <R> Fallback<R> |
Fallback.ofStage(CheckedFunction<ExecutionAttemptedEvent<? extends R>,? extends CompletionStage<R>> fallback)
Returns the
fallback to be executed if execution fails. |
Copyright © 2022. All rights reserved.