static <R> CircuitBreakerBuilder<R> |
CircuitBreaker.builder() |
Creates a CircuitBreakerBuilder that by default will build a count based circuit breaker that opens after a single failure , closes after a single success , and has a 1 minute delay , unless configured otherwise.
|
static <R> CircuitBreakerBuilder<R> |
CircuitBreaker.builder(CircuitBreakerConfig<R> config) |
Creates a new CircuitBreakerBuilder that will be based on the config .
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.onClose(EventListener<CircuitBreakerStateChangedEvent> listener) |
Calls the listener when the circuit is closed.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.onHalfOpen(EventListener<CircuitBreakerStateChangedEvent> listener) |
Calls the listener when the circuit is half-opened.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.onOpen(EventListener<CircuitBreakerStateChangedEvent> listener) |
Calls the listener when the circuit is opened.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.withDelay(java.time.Duration delay) |
Sets the delay to wait in OPEN state before transitioning to half-open.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.withFailureRateThreshold(int failureRateThreshold,
int failureExecutionThreshold,
java.time.Duration failureThresholdingPeriod) |
Configures time based failure rate thresholding by setting the percentage rate of failures, from 1 to 100, that
must occur within the rolling failureThresholdingPeriod when in a CLOSED state in order to open the
circuit.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.withFailureThreshold(int failureThreshold) |
Configures count based failure thresholding by setting the number of consecutive failures that must occur when in a
CLOSED state in order to open the circuit.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.withFailureThreshold(int failureThreshold,
int failureThresholdingCapacity) |
Configures count based failure thresholding by setting the ratio of failures to executions that must occur when in
a CLOSED state in order to open the circuit.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.withFailureThreshold(int failureThreshold,
int failureExecutionThreshold,
java.time.Duration failureThresholdingPeriod) |
Configures time based failure thresholding by setting the number of failures that must occur within the
failureThresholdingPeriod when in a CLOSED state in order to open the circuit.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.withFailureThreshold(int failureThreshold,
java.time.Duration failureThresholdingPeriod) |
Configures time based failure thresholding by setting the number of failures that must occur within the
failureThresholdingPeriod when in a CLOSED state in order to open the circuit.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.withSuccessThreshold(int successThreshold) |
Configures count based success thresholding by setting the number of consecutive successful executions that must
occur when in a HALF_OPEN state in order to close the circuit, else the circuit is re-opened when a failure
occurs.
|
CircuitBreakerBuilder<R> |
CircuitBreakerBuilder.withSuccessThreshold(int successThreshold,
int successThresholdingCapacity) |
Configures count based success thresholding by setting the ratio of successful executions that must occur when in a
HALF_OPEN state in order to close the circuit.
|