Design Patterns · Senior · Question 42 of 75

How does the Circuit Breaker pattern help the client when an API fails?

Explanation

States: closed (requests go through), open (immediate failure or fallback), half-open (trial requests). This prevents an avalanche of retries to a failed service and gives the user a fast response with degraded functionality.

Further reading

Problem with a question

Design Patterns · Senior · question 42

Test yourself

Take the Design Patterns · Senior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz