org.squbs.streams.circuitbreaker.impl
used to differentiate circuit breakers in metrics
used to schedule reset attempt
maximum number of failures before opening the circuit
scala.concurrent.duration.FiniteDuration of time after which to consider a call a failure
scala.concurrent.duration.FiniteDuration of time after which to attempt to close the circuit
the upper bound of resetTimeout
The exponential amount that the wait time will be increased
scala.concurrent.ExecutionContext used for execution of the scheduler
Attempts to reset breaker by transitioning to HalfOpen state.
Attempts to reset breaker by transitioning to HalfOpen state. This is valid from Open state only.
scala.concurrent.duration.FiniteDuration of time after which to consider a call a failure
scala.concurrent.duration.FiniteDuration of time after which to consider a call a failure
Check if circuit should be short circuited.
Check if circuit should be short circuited.
Get the current state of the Circuit Breaker.
Get the current state of the Circuit Breaker.
the current state
The exponential amount that the wait time will be increased
The exponential amount that the wait time will be increased
Mark a failed call through CircuitBreaker.
Mark a failed call through CircuitBreaker.
Check if circuit should be short circuited.
Check if circuit should be short circuited.
true if short circuited
Mark a failed element/response/call through CircuitBreaker.
Mark a failed element/response/call through CircuitBreaker.
Mark a successful element/response/call through CircuitBreaker.
Mark a successful element/response/call through CircuitBreaker.
maximum number of failures before opening the circuit
maximum number of failures before opening the circuit
the upper bound of resetTimeout
the upper bound of resetTimeout
used to differentiate circuit breakers in metrics
used to differentiate circuit breakers in metrics
Resets breaker to Closed state.
Resets breaker to Closed state. This is valid from HalfOpen state only.
scala.concurrent.duration.FiniteDuration of time after which to attempt to close the circuit
scala.concurrent.duration.FiniteDuration of time after which to attempt to close the circuit
Subscribe an ActorRef to receive events that it's interested in.
Subscribe an ActorRef to receive events that it's interested in.
ActorRef that would receive the events
event types that this ActorRef is interested in
true if subscription is successful
Mark a successful call through CircuitBreaker.
Mark a successful call through CircuitBreaker.
Implements consistent transition between states.
Implements consistent transition between states. Throws IllegalStateException if an invalid transition is attempted.
State being transitioning from
State being transitioning to
Implements consistent transition between states.
Implements consistent transition between states. Throws IllegalStateException if an invalid transition is attempted.
State being transitioning from
State being transitioning from
Trips breaker to an open state.
Trips breaker to an open state. This is valid from Closed or HalfOpen states.
State we're coming from (Closed or HalfOpen)
The provided MetricRegistry will be used to register metrics
The provided MetricRegistry will be used to register metrics
the registry to use for codahale metrics
A CircuitBreakerState implementation based on
Atomicvariables.