Interface CircuitBreaker
-
- All Known Implementing Classes:
ExecutorCircuitBreaker
,JavaRuntimeCircuitBreaker
,NoOpCircuitBreaker
,SimpleMemoryCircuitBreaker
,StaticCircuitBreaker
public interface CircuitBreaker
-
-
Field Summary
Fields Modifier and Type Field Description static int
CIRCUIT_CHECK_INTERVAL_IN_MILLIS
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description CircuitBreakerState
currentState()
default int
getCheckIntervalMillis()
<T> T
run(java.util.concurrent.Callable<T> callable)
-
-
-
Field Detail
-
CIRCUIT_CHECK_INTERVAL_IN_MILLIS
static final int CIRCUIT_CHECK_INTERVAL_IN_MILLIS
- See Also:
- Constant Field Values
-
-
Method Detail
-
currentState
CircuitBreakerState currentState()
-
run
<T> T run(java.util.concurrent.Callable<T> callable)
- Type Parameters:
T
- callable generic type- Parameters:
callable
- The callable to be run- Returns:
- result of callable
-
getCheckIntervalMillis
default int getCheckIntervalMillis()
-
-