Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HttpClientDetails ¶
type HttpClientDetails struct {
User string
Password string
ApiKey string
AccessToken string
Headers map[string]string
Transport *http.Transport
DialTimeout time.Duration
OverallRequestTimeout time.Duration
// Prior to each retry attempt, the list of PreRetryInterceptors is invoked sequentially. If any of these interceptors yields a 'false' response, the retry process stops instantly.
PreRetryInterceptors []PreRetryInterceptor
}
func (*HttpClientDetails) AddPreRetryInterceptor ¶
func (httpClientDetails *HttpClientDetails) AddPreRetryInterceptor(preRetryInterceptors PreRetryInterceptor)
func (HttpClientDetails) Clone ¶
func (httpClientDetails HttpClientDetails) Clone() *HttpClientDetails
type PollingAction ¶
type PollingExecutor ¶
type PollingExecutor struct {
// Maximum wait time in nanoseconds.
Timeout time.Duration
// Number of nanoseconds to sleep between polling attempts.
PollingInterval time.Duration
// Prefix to add at the beginning of each info/error message.
MsgPrefix string
// pollingAction is the operation to run until the condition fulfilled.
PollingAction PollingAction
}
func (*PollingExecutor) Execute ¶
func (runner *PollingExecutor) Execute() ([]byte, error)
type PreRetryInterceptor ¶
type PreRetryInterceptor func() (shouldRetry bool)
Click to show internal directories.
Click to hide internal directories.