public class DefaultTimeLimiterProvider extends Object implements TimeLimiterProvider, GenericDecoratorAsync
Constructor and Description |
---|
DefaultTimeLimiterProvider() |
Modifier and Type | Method and Description |
---|---|
<T> Callable<T> |
decorateCallable(ResilienceConfiguration configuration,
Callable<T> callable,
ExecutorService executor)
Decorates the given callable to enable a resilient property.
|
io.github.resilience4j.timelimiter.TimeLimiter |
getTimeLimiter(ResilienceConfiguration configuration)
Provides a time limiter.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
decorateCallable
@Nonnull public <T> Callable<T> decorateCallable(@Nonnull ResilienceConfiguration configuration, @Nonnull Callable<T> callable, @Nonnull ExecutorService executor)
decorateCallable
in interface GenericDecoratorAsync
T
- The type of the callable.configuration
- The configuration to be used.callable
- The callable to decorate.executor
- The executor service instance to run asynchronous tasks with.@Nonnull public io.github.resilience4j.timelimiter.TimeLimiter getTimeLimiter(@Nonnull ResilienceConfiguration configuration)
getTimeLimiter
in interface TimeLimiterProvider
configuration
- The configuration for constructing the time limiter.Copyright © 2021 SAP SE. All rights reserved.