A sample java implementation of a circuit breaker (Hystrix) together with a retry mechanism (Failsafe).
The retry is encapsulated in the http client (MyHttpClient
). When a Hystrix command is using MyHttpClient
it isn't aware of retries.
In fact, timeout responsibility is handled to retry and is disabled on the command.
mvn install
- Throwing a
HystrixTimeoutException
will be considered asFAILURE
exuction exception and notTIMEOUT
, unlessexecution.timeout.enabled
is false