Documentation
¶
Overview ¶
Package wait provides functionality for handling waiting and retrying operations.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var SkipRetry = errors.New("skip retry")
SkipRetry is used as a return value from ForFunc
Functions ¶
func ForFunc ¶ added in v0.9.0
ForFunc waits for function to return non-nil error within the specified timeout. It uses exponential backoff to retry requests until the endpoint responds successfully or the context is canceled.
func ForHTTP ¶
func ForHTTP(ctx context.Context, timeout time.Duration, endpoint string, opts ...func(*http.Request)) error
ForHTTP waits for an HTTP endpoint to become available within the specified timeout. It uses exponential backoff to retry requests until the endpoint responds successfully or the context is canceled.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.