Documentation ¶
Index ¶
- func Module() *module.Module
- func SetErrorFilter(ctx context.Context, filter func(error) (bool, error)) context.Context
- func SetFallbackFunc(ctx context.Context, fb func(context.Context, error) (interface{}, error)) context.Context
- type Base
- type CircuitRoundTripper
- type DelayType
- type DriverWrapper
- type ErrDecoder
- type Factory
- type GenericClientError
- type Option
- type RetryRoundTripper
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetErrorFilter ¶
Types ¶
type CircuitRoundTripper ¶
type CircuitRoundTripper struct {
// contains filtered or unexported fields
}
type DriverWrapper ¶
func WithTransport ¶
func WithTransport(tr http.RoundTripper) DriverWrapper
type ErrDecoder ¶
func DefaultErrDecoder ¶
func DefaultErrDecoder(name string) ErrDecoder
type Factory ¶
type Factory struct {
// contains filtered or unexported fields
}
func NewFactory ¶
func NewFactory(cfg *config.Config, wrappers []DriverWrapper) *Factory
type GenericClientError ¶ added in v0.1.4
type GenericClientError struct { ClientName string StatusCode int RawBody []byte ParsedBody interface{} }
func (GenericClientError) Error ¶ added in v0.1.4
func (e GenericClientError) Error() string
func (GenericClientError) Status ¶
func (e GenericClientError) Status() int
type Option ¶ added in v0.1.4
type Option interface {
Apply(*options)
}
func WithDriverWrappers ¶ added in v0.1.4
func WithDriverWrappers(wrappers ...DriverWrapper) Option
func WithErrDecoder ¶ added in v0.1.4
func WithErrDecoder(ed ErrDecoder) Option
type RetryRoundTripper ¶
type RetryRoundTripper struct {
// contains filtered or unexported fields
}
Source Files ¶
Click to show internal directories.
Click to hide internal directories.