(with-circuit-breaker circuit {:keys [tripped connected]})
If circuit breaker is tripped, run tripped, else run connected. If the connected function throws an error, it won't cause the circuit to trip.
If circuit breaker is tripped, run tripped, else run connected. If the connected function throws an error, it won't cause the circuit to trip.
(wrap-with-circuit-breaker circuit-name method-that-might-error)
(wrap-with-circuit-breaker circuit-name method-that-might-error tripped-method)
If specified circuit breaker isn't tripped, run method-that-might-error. If circuit breaker is tripped, run tripped-method if specified, else return nil.
If specified circuit breaker isn't tripped, run method-that-might-error. If circuit breaker is tripped, run tripped-method if specified, else return nil.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close