modulepackage
1.0.0
Repository: https://github.com/paulusrobin/gogen-golib.git
Documentation: pkg.go.dev
# Functions
DefaultReadyToTrip default function for circuit breaker.
NewCircuitBreakerClient function to instantiate http client.
WithCounterErrorSkipper function to bring counter error skipper to circuit breaker.
WithHTTPClient function to override http client doer.
WithInterval function to override circuit breaker interval.
WithMaxRequests function to override circuit breaker max requests.
WithOnStateChangeFunc function to run hook on state change.
WithReadyToTripFunc function to run hook on state change.
WithTimeout function to override http client timeout.
# Interfaces
Options interface to extend circuit breaker client.
# Type aliases
CounterErrorSkipperFunc function skipper circuit breaker counter return true to skip.
OnStateChangeFunc on state change hook.
ReadyToTripFunc on ready to trip.