public class CircuitBreakerWrapperHelper
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static <T> T |
wrapWithCircuitBreaker(T target,
io.github.resilience4j.circuitbreaker.CircuitBreaker circuitBreaker)
Wraps all calls on target using a circuit breaker.
|
public static <T> T wrapWithCircuitBreaker(T target, io.github.resilience4j.circuitbreaker.CircuitBreaker circuitBreaker)
T
- The type of the target.target
- The target to wrap. Final classes have to implement an interface. (e.g. a Jersey
client proxy).circuitBreaker
- The circuit breaker to use.