Uses of Class
dev.failsafe.FallbackBuilder
Packages that use FallbackBuilder
-
Uses of FallbackBuilder in dev.failsafe
Methods in dev.failsafe that return FallbackBuilderModifier and TypeMethodDescriptionstatic <R> FallbackBuilder
<R> Fallback.builder
(FallbackConfig<R> config) Creates a new FallbackBuilder that will be based on theconfig
.static <R> FallbackBuilder
<R> Fallback.builder
(CheckedConsumer<ExecutionAttemptedEvent<? extends R>> fallback) Returns thefallback
to be executed if execution fails.static <R> FallbackBuilder
<R> Fallback.builder
(CheckedFunction<ExecutionAttemptedEvent<? extends R>, ? extends R> fallback) Returns thefallback
to be executed if execution fails.static <R> FallbackBuilder
<R> Fallback.builder
(CheckedRunnable fallback) Returns thefallback
to be executed if execution fails.static <R> FallbackBuilder
<R> Fallback.builder
(CheckedSupplier<? extends R> fallback) Returns thefallback
to be executed if execution fails.static <R> FallbackBuilder
<R> Fallback.builder
(R fallbackResult) Returns thefallbackResult
to be provided if execution fails.static <R> FallbackBuilder
<R> Fallback.builderOfException
(CheckedFunction<ExecutionAttemptedEvent<? extends R>, ? extends Exception> fallback) Returns thefallback
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 thefallback
to be executed if execution fails.static <R> FallbackBuilder
<R> Fallback.builderOfStage
(CheckedSupplier<? extends CompletionStage<R>> fallback) Returns thefallback
to be executed if execution fails.FallbackBuilder.onFailedAttempt
(EventListener<ExecutionAttemptedEvent<R>> listener) Registers thelistener
to be called when the last execution attempt prior to the fallback failed.FallbackBuilder.withAsync()
Configures the fallback to run asynchronously.