Fuse principle

Fuse principle

Fuse, also called circuit breaker, its English word is: Circuit Breaker

The 3 states of the fusing state machine:

  • Closed: Closed state, all requests are accessed normally.
  • Open: Open state, all requests will be downgraded. Hystix counts the request status. When the percentage of failed requests reaches the threshold within a certain period of time, the fuse is triggered and the circuit breaker is fully opened. The default failure rate threshold is 50%, and the number of requests is at least 20 times.
  • Half Open: Half-open state. The open state is not permanent. It will enter the sleep time after being opened (the default is 5S). Then the circuit breaker will automatically enter the half-open state. At this time, some requests will be released. If these requests are healthy, the circuit breaker will be completely closed, otherwise the circuit breaker will remain open, and the sleep timer will be performed again.

Guess you like

Origin blog.csdn.net/m0_51684972/article/details/115057880