errutil

package
v2.0.0-alpha.17 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 6, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsMemoryErr

func IsMemoryErr(err error) bool

func IsRetryableHTTP

func IsRetryableHTTP(err error) (retryType string, isRetryable bool)

IsRetryableHTTP returns if the provided error is considered retryable HTTP error. It also returns the type, in string form, for optional logging and metrics use.

func IsRetryableNetwork

func IsRetryableNetwork(err error) (retryType string, isRetryable bool)

IsRetryableNetwork returns if the provided error is a retryable network related error. It also returns the type, in string form, for optional logging and metrics use.

func IsTemporary

func IsTemporary(err error) bool

IsTemporary returns true if the provided error is considered retryable temporary error by testing if it complies with an interface implementing `Temporary() bool` and calling the function.

func IsTemporaryConnection

func IsTemporaryConnection(err error) (retryType string, isRetryable bool)

IsTemporaryConnection returns if the provided error was a low level retryable connection error. It also returns the type, in string form, for optional logging and metrics use.

func IsTimeout

func IsTimeout(err error) bool

IsTimeout returns true if the provided error is considered a retryable timeout error by testing if it complies with an interface implementing `Timeout() bool` and calling the function.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL