Class CircuitBreakerService
- java.lang.Object
-
- org.elasticsearch.common.component.AbstractLifecycleComponent
-
- org.elasticsearch.indices.breaker.CircuitBreakerService
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable,LifecycleComponent,Releasable
- Direct Known Subclasses:
HierarchyCircuitBreakerService,NoneCircuitBreakerService
public abstract class CircuitBreakerService extends AbstractLifecycleComponent
Interface for Circuit Breaker services, which provide breakers to classes that load field data.
-
-
Field Summary
-
Fields inherited from class org.elasticsearch.common.component.AbstractLifecycleComponent
lifecycle
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedCircuitBreakerService(Settings settings)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voiddoClose()protected voiddoStart()protected voiddoStop()abstract CircuitBreakergetBreaker(java.lang.String name)abstract voidregisterBreaker(BreakerSettings breakerSettings)Allows to register of a custom circuit breaker.abstract AllCircuitBreakerStatsstats()abstract CircuitBreakerStatsstats(java.lang.String name)-
Methods inherited from class org.elasticsearch.common.component.AbstractLifecycleComponent
addLifecycleListener, close, lifecycleState, removeLifecycleListener, start, stop
-
-
-
-
Constructor Detail
-
CircuitBreakerService
protected CircuitBreakerService(Settings settings)
-
-
Method Detail
-
registerBreaker
public abstract void registerBreaker(BreakerSettings breakerSettings)
Allows to register of a custom circuit breaker.
-
getBreaker
public abstract CircuitBreaker getBreaker(java.lang.String name)
- Returns:
- the breaker that can be used to register estimates against
-
stats
public abstract AllCircuitBreakerStats stats()
- Returns:
- stats about all breakers
-
stats
public abstract CircuitBreakerStats stats(java.lang.String name)
- Returns:
- stats about a specific breaker
-
doStart
protected void doStart()
- Specified by:
doStartin classAbstractLifecycleComponent
-
doStop
protected void doStop()
- Specified by:
doStopin classAbstractLifecycleComponent
-
doClose
protected void doClose()
- Specified by:
doClosein classAbstractLifecycleComponent
-
-