Class CircuitBreaker

  • Direct Known Subclasses:
    CPUCircuitBreaker, MemoryCircuitBreaker

    public abstract class CircuitBreaker
    extends Object
    Default class to define circuit breakers for Solr.

    There are two (typical) ways to use circuit breakers: 1. Have them checked at admission control by default (use CircuitBreakerManager for the same). 2. Use the circuit breaker in a specific code path(s).

    TODO: This class should be grown as the scope of circuit breakers grow.

    The class and its derivatives raise a standard exception when a circuit breaker is triggered. We should make it into a dedicated exception (https://issues.apache.org/jira/browse/SOLR-14755)