Circuit Breaker Pattern — Concept Check
Questions on Circuit Breaker Pattern. When failure rate exceeds a threshold the circuit "opens", short-circuiting calls and returning a fallback; after a wait it goes half-open to probe recovery.
Questions in this quiz
7 questions on Circuit Breaker Pattern — Concept Check. Work through them here, then start the quiz to answer them and see your score.
1.A service using a circuit breaker pattern experiences a high failure rate and transitions to the OPEN state. What happens to incoming requests during this state?
- ARequests are processed normally but with a delay.
- BRequests are immediately rejected and a fallback is returned.
- CRequests are queued until the service recovers.
- DRequests are retried with exponential backoff.
2.You have configured a circuit breaker with a failure rate threshold of 50% over the last 10 calls. If 6 out of 10 calls fail, what state will the circuit breaker transition to?
- AHALF-OPEN
- BTRIPPED
- CCLOSED
- DOPEN
3.After a circuit breaker transitions to the OPEN state, what determines when it moves to the HALF-OPEN state?
- AA decrease in incoming request load.
- BA successful retry from the client.
- CA manual reset by an administrator.
- DA fixed wait duration in the OPEN state.
4.A developer notices that the circuit breaker is frequently transitioning to the OPEN state. What could be a potential cause?
- AIncorrect fallback method implementation.
- BToo many test calls in HALF-OPEN state.
- CHigh failure rate of downstream service calls.
- DInsufficient circuit breaker configuration.
5.In a HALF-OPEN state, a circuit breaker allows a limited number of test calls. What happens if these calls fail?
- AThe circuit transitions to CLOSED.
- BThe circuit resets to its initial state.
- CThe circuit transitions back to OPEN.
- DThe circuit remains HALF-OPEN and retries.
6.A service is experiencing latency spikes due to repeated failed calls to a downstream service. How can the circuit breaker pattern help?
- ABy short-circuiting calls and using a fallback when failures exceed a threshold.
- BBy increasing the number of retries to the downstream service.
- CBy distributing the load evenly across multiple instances.
- DBy caching successful responses for future requests.
7.A developer configures a circuit breaker with a COUNT_BASED sliding window. What does this mean for failure counting?
- AFailures are counted indefinitely until reset.
- BFailures are counted based on a fixed time interval.
- CFailures are counted only when exceptions occur.
- DFailures are counted based on the number of recent calls.