Documentation ¶
Index ¶
- Variables
- func AsConnectError(err error) error
- func ErrorType(err error) string
- func IgnoreNotFoundErr[T any](in T, err error) (T, error)
- func IsInvalidArgumentError(err error) bool
- func IsRetryableError(err error) bool
- func NewInvalidArgumentError(f string, vs ...any) error
- func NewRetryableError(err error) error
- func NewRetryableErrorf(f string, vs ...any) error
- type ErrInvalidArgument
- type RetryableError
- type TypedError
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNotImplemented = newTypedError("not_implemented") ErrAlreadyExists = newTypedError("already_exists") ErrNotFound = newTypedError("not_found") ErrConflict = newTypedError("conflict") ErrUnauthenticated = newTypedError("unauthenticated") ErrUnknown = NewRetryableErrorf("unknown") ErrFailedPrecondition = newTypedError("failed_precondition") ErrLimitExceeded = NewRetryableErrorf("limit_exceeded") ErrProgram = newTypedError("program_error") )
Functions ¶
func AsConnectError ¶ added in v0.3.0
re-wrap sdk as connect error
func IgnoreNotFoundErr ¶
func IsInvalidArgumentError ¶ added in v0.10.12
func IsRetryableError ¶ added in v0.10.9
func NewInvalidArgumentError ¶ added in v0.3.0
func NewRetryableError ¶ added in v0.10.2
func NewRetryableErrorf ¶ added in v0.10.12
Types ¶
type ErrInvalidArgument ¶
type ErrInvalidArgument struct {
Underlying error
}
func (ErrInvalidArgument) Error ¶ added in v0.3.0
func (e ErrInvalidArgument) Error() string
func (ErrInvalidArgument) ErrorType ¶ added in v0.10.12
func (e ErrInvalidArgument) ErrorType() string
func (ErrInvalidArgument) Unwrap ¶ added in v0.3.0
func (e ErrInvalidArgument) Unwrap() error
type RetryableError ¶ added in v0.10.2
type RetryableError struct {
Err error
}
func (*RetryableError) Error ¶ added in v0.10.2
func (e *RetryableError) Error() string
func (*RetryableError) ErrorType ¶ added in v0.10.12
func (e *RetryableError) ErrorType() string
func (*RetryableError) Unwrap ¶ added in v0.10.2
func (e *RetryableError) Unwrap() error
type TypedError ¶ added in v0.10.12
type TypedError interface{ ErrorType() string }
Click to show internal directories.
Click to hide internal directories.