Documentation
¶
Index ¶
- Constants
- func NewRateLimit(client nw_client.Rest, rate int, headerType RetryAfterHeaderType, ...) nw_client.Rest
- func NewServerError(client nw_client.Rest, rate, code int, decorator ResponseDecorator) nw_client.Rest
- func NoDecorator(endpoint string, res *http.Response)
- type MockApiContext
- type MockReqBuilder
- type PanicClient
- type ResponseDecorator
- type RetryAfterHeaderType
Constants ¶
View Source
const ( RetryAfterHeaderRetryAfter = iota RetryAfterHeaderGitHub RetryAfterHeaderIetfDraftSecond RetryAfterHeaderIetfDraftTimestamp )
Variables ¶
This section is empty.
Functions ¶
func NewRateLimit ¶
func NewRateLimit(client nw_client.Rest, rate int, headerType RetryAfterHeaderType, decorator ResponseDecorator) nw_client.Rest
func NewServerError ¶
func NoDecorator ¶
Types ¶
type MockApiContext ¶
type MockApiContext struct {
}
func (MockApiContext) Capture ¶
func (z MockApiContext) Capture() esl.Logger
func (MockApiContext) ClientHash ¶
func (z MockApiContext) ClientHash() string
func (MockApiContext) Log ¶
func (z MockApiContext) Log() esl.Logger
func (MockApiContext) Name ¶
func (z MockApiContext) Name() string
type MockReqBuilder ¶
type MockReqBuilder struct {
}
func (MockReqBuilder) Endpoint ¶
func (z MockReqBuilder) Endpoint() string
func (MockReqBuilder) Param ¶
func (z MockReqBuilder) Param() string
type PanicClient ¶
type PanicClient struct {
}
func (PanicClient) Call ¶
func (p PanicClient) Call(ctx api_context.Context, req nw_client.RequestBuilder) (res es_response.Response)
type ResponseDecorator ¶
type RetryAfterHeaderType ¶
type RetryAfterHeaderType int
Click to show internal directories.
Click to hide internal directories.