package
1.1.0
Repository: https://github.com/cognusion/oxy.git
Documentation: pkg.go.dev

# Functions

CheckPeriod is how long the CircuitBreaker will wait between successive checks of the breaker condition.
Clock allows you to fake che CircuitBreaker's view of the current time.
Fallback defines the http.Handler that the CircuitBreaker should route requests to when it prevents a request from taking its normal path.
FallbackDuration is how long the CircuitBreaker will remain in the Tripped state before trying to recover.
Logger defines the logger the circuit breaker will use.
New creates a new CircuitBreaker middleware.
NewRedirectFallback creates a new RedirectFallback.
NewRedirectFallbackWithLogger creates a new RedirectFallback.
NewResponseFallback creates a new ResponseFallback.
NewResponseFallbackWithLogger creates a new ResponseFallback.
NewWebhookSideEffect creates a new WebhookSideEffect.
NewWebhookSideEffectsWithLogger creates a new WebhookSideEffect.
OnStandby sets a SideEffect to run when entering the Standby state.
OnTripped sets a SideEffect to run when entering the Tripped state.
RecoveryDuration is how long the CircuitBreaker will take to ramp up requests during the Recovering state.

# Structs

CircuitBreaker is http.Handler that implements circuit breaker pattern.
Redirect redirect model.
RedirectFallback fallback redirect handler.
Response response model.
ResponseFallback fallback response handler.
Webhook Web hook.
WebhookSideEffect a web hook side effect.

# Interfaces

SideEffect a side effect.

# Type aliases

CircuitBreakerOption represents an option you can pass to New.