Versions in this module Expand all Collapse all v1 v1.3.0 Sep 15, 2025 Changes in this version + var CircuteBreakerForJust429 = gobreaker.NewCircuitBreaker(gobreaker.Settings{ ... }) + type BackoffStrategyExpnential struct + func NewRetryInterceptor_BackoffStrategyLinier(baseDuration time.Duration) BackoffStrategyExpnential + func NewRetryInterceptor_ExponentialBackoff(baseDuration, maxBackoff time.Duration) BackoffStrategyExpnential + func (b BackoffStrategyExpnential) TimeToWait(iteration int) time.Duration + type BackoffStrategyLinier struct + func (b BackoffStrategyLinier) TimeToWait(iteration int) time.Duration + type BackoffTimer interface + TimeToWait func(iteration int) time.Duration + type CircuitBreakerInterceptor struct + func NewCircuitBreakerInterceptor(cb *gobreaker.CircuitBreaker, abortOnFailure bool) *CircuitBreakerInterceptor + func (c *CircuitBreakerInterceptor) AfterResponse(data InterceptorData) InterceptorData + func (c *CircuitBreakerInterceptor) BeforeRequest(data InterceptorData) InterceptorData + type ClientHandler interface + ProcessRequest func(httpRequest *http.Request, successCode int, id string) (*http.Response, error) + type ClientInterceptor interface + AfterResponse func(InterceptorData) InterceptorData + BeforeRequest func(InterceptorData) InterceptorData + type InterceptorData struct + Context context.Context + Error error + ID string + InitialRequest *http.Request + Request *http.Request + Response *http.Response + type RetryDecider interface + ShouldRetry func(*http.Response, error, RetryInternalData) (bool, error) + type RetryDeciderAll struct + func NewRetryInterceptor_RetryDeciderAll(maxRetries int) RetryDeciderAll + func (r RetryDeciderAll) ShouldRetry(response *http.Response, err error, retryData RetryInternalData) (bool, error) + type RetryInterceptor struct + func NewRetryInterceptor(clientHandler ClientHandler, backoffStrategy BackoffTimer, ...) *RetryInterceptor + func (e *RetryInterceptor) AfterResponse(data InterceptorData) InterceptorData + func (e *RetryInterceptor) BeforeRequest(data InterceptorData) InterceptorData + type RetryInternalData struct + RetryCount int