Package io.github.resilience4j.fallback
Class DefaultFallbackDecorator
java.lang.Object
io.github.resilience4j.fallback.DefaultFallbackDecorator
- All Implemented Interfaces:
FallbackDecorator
default fallbackMethod decorator. it catches throwable and invoke the fallbackMethod method.
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
DefaultFallbackDecorator
public DefaultFallbackDecorator()
-
-
Method Details
-
supports
- Specified by:
supports
in interfaceFallbackDecorator
-
decorate
public io.github.resilience4j.core.functions.CheckedSupplier<Object> decorate(FallbackMethod fallbackMethod, io.github.resilience4j.core.functions.CheckedSupplier<Object> supplier) - Specified by:
decorate
in interfaceFallbackDecorator
- Parameters:
fallbackMethod
- fallback method.supplier
- target function should be decorated.- Returns:
- decorated function
-