public interface CircuitBreakerStateChangeObserver
| Modifier and Type | Method and Description |
|---|---|
void |
onStateChange(CircuitBreaker.State prevState,
CircuitBreaker.State newState,
DegradeRule rule,
Double snapshotValue)
Observer method triggered when circuit breaker state changed.
|
void onStateChange(CircuitBreaker.State prevState, CircuitBreaker.State newState, DegradeRule rule, Double snapshotValue)
Observer method triggered when circuit breaker state changed. The transformation could be:
CLOSED to OPEN (with the triggered metric)OPEN to HALF_OPENOPEN to CLOSEDHALF_OPEN to OPEN (with the triggered metric)prevState - previous state of the circuit breakernewState - new state of the circuit breakerrule - associated rulesnapshotValue - triggered value on circuit breaker opens (null if the new state is CLOSED or HALF_OPEN)Copyright © 2021 Alibaba Group. All rights reserved.