Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidStatusCode = errors.New("invalid status code")
ErrInvalidStatusCode for http retry.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Timeout time.Duration `yaml:"timeout" json:"timeout"` Attempts uint `yaml:"attempts" json:"attempts"` }
Config for retry.
type RoundTripper ¶
type RoundTripper struct { http.RoundTripper // contains filtered or unexported fields }
RoundTripper for retry.
func NewRoundTripper ¶
func NewRoundTripper(cfg *Config, hrt http.RoundTripper) *RoundTripper
NewRoundTripper for retry.
Click to show internal directories.
Click to hide internal directories.