Day 48: Cloud pattern: circuit breakers
In a large cloud infrastructure with lot of instances of a service, circuit breaker helps to detect unhealthy nodes when errors raise.
For example, we can implement a circuit breaker in a load balancer, by tracking the number (or ratio) of 5xx http errors a service is returning or the average response time.
Associating circuit breakers to a deployment process allows auto-revert when bad releases are deployed into production. \o/
Implementation examples and papers
- Netflix: https://github.com/Netflix/Hystrix/wiki/How-it-Works
- Uber: https://github.com/uber/tchannel/blob/master/docs/circuit-breaking.md
- Martin Fowler: https://martinfowler.com/bliki/CircuitBreaker.html
by ops for non-ops