Uses of Interface
dev.failsafe.Policy
-
Packages that use Policy Package Description dev.failsafe APIs for performing failsafe executions.dev.failsafe.internal dev.failsafe.spi The Failsafe Service Provider Interface (SPI). -
-
Uses of Policy in dev.failsafe
Subinterfaces of Policy in dev.failsafe Modifier and Type Interface Description interfaceBulkhead<R>A bulkhead allows you to restrict concurrent executions as a way of preventing system overload.interfaceCircuitBreaker<R>A circuit breaker temporarily blocks execution when a configured number of failures are exceeded.interfaceFallback<R>A Policy that handles failures using a fallback function or result.interfaceRateLimiter<R>A rate limiter allows you to control the rate of executions as a way of preventing system overload.interfaceRetryPolicy<R>A policy that defines when retries should be performed.interfaceTimeout<R>A policy that cancels and fails an excecution with aTimeoutExceededExceptionif a timeout is exceeded.Fields in dev.failsafe with type parameters of type Policy Modifier and Type Field Description (package private) java.util.List<? extends Policy<R>>FailsafeExecutor. policiesPolicies sorted outermost firstMethods in dev.failsafe with type parameters of type Policy Modifier and Type Method Description <P extends Policy<R>>
FailsafeExecutor<R>FailsafeExecutor. compose(P innerPolicy)Returns a newFailsafeExecutorthat composes the currently configured policies around the giveninnerPolicy.static <R,P extends Policy<R>>
FailsafeExecutor<R>Failsafe. with(P outerPolicy, P... policies)Creates and returns a newFailsafeExecutorinstance that will handle failures according to the givenouterPolicyandpolicies.Methods in dev.failsafe that return types with arguments of type Policy Modifier and Type Method Description java.util.List<? extends Policy<R>>FailsafeExecutor. getPolicies()Returns the currently configured policies.Methods in dev.failsafe with parameters of type Policy Modifier and Type Method Description static <R> Execution<R>Execution. of(Policy<R> outerPolicy, Policy<R>... policies)Creates a newExecutionthat will use theouterPolicyandinnerPoliciesto handle failures.static <R,P extends Policy<R>>
FailsafeExecutor<R>Failsafe. with(P outerPolicy, P... policies)Creates and returns a newFailsafeExecutorinstance that will handle failures according to the givenouterPolicyandpolicies.Method parameters in dev.failsafe with type arguments of type Policy Modifier and Type Method Description static <R> FailsafeExecutor<R>Failsafe. with(java.util.List<? extends Policy<R>> policies)Creates and returns a newFailsafeExecutorinstance that will handle failures according to the givenpolicies.Constructor parameters in dev.failsafe with type arguments of type Policy Constructor Description AsyncExecutionImpl(java.util.List<Policy<R>> policies, Scheduler scheduler, FailsafeFuture<R> future, boolean asyncExecution, java.util.function.Function<AsyncExecutionInternal<R>,java.util.concurrent.CompletableFuture<ExecutionResult<R>>> innerFn)ExecutionImpl(java.util.List<? extends Policy<R>> policies)Creates a new execution for thepolicies.FailsafeExecutor(java.util.List<? extends Policy<R>> policies)SyncExecutionImpl(java.util.List<? extends Policy<R>> policies)Create a standalone sync execution for thepolicies. -
Uses of Policy in dev.failsafe.internal
Classes in dev.failsafe.internal that implement Policy Modifier and Type Class Description classBulkheadImpl<R>A Bulkhead implementation that supports sync and async waiting.classCircuitBreakerImpl<R>ACircuitBreakerimplementation.classFallbackImpl<R>AFallbackimplementation.classRateLimiterImpl<R>A RateLimiter implementation that supports smooth and bursty rate limiting.classRetryPolicyImpl<R>ARetryPolicyimplementation.classTimeoutImpl<R>ATimeoutimplementation. -
Uses of Policy in dev.failsafe.spi
Subinterfaces of Policy in dev.failsafe.spi Modifier and Type Interface Description interfaceDelayablePolicy<R>A policy that can be delayed between executions.interfaceFailurePolicy<R>A policy that can handle specifically configured failures.Constructors in dev.failsafe.spi with parameters of type Policy Constructor Description PolicyExecutor(Policy<R> policy, int policyIndex)
-