clouderror

package
v0.60.0 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Wrap

func Wrap(err error, s *status.Status) error

Wrap an error with a gRPC status.

func WrapCaller

func WrapCaller(err error, s *status.Status, caller Caller) error

WrapCaller wraps an error with a gRPC status and a caller.

func WrapTransient

func WrapTransient(err error, msg string) error

WrapTransient wraps transient errors (possibly status.Status) with appropriate codes.Code. The returned error will always be a status.Status with description set to msg.

func WrapTransientCaller

func WrapTransientCaller(err error, msg string, caller Caller) error

WrapTransientCaller wraps transient errors with an appropriate codes.Code and caller. The returned error will always be a status.Status with description set to msg.

Types

type Caller

type Caller struct {
	// contains filtered or unexported fields
}

Caller is the caller info for an error.

func NewCaller

func NewCaller(pc uintptr, file string, line int, ok bool) Caller

NewCaller creates a new caller.

Jump to

Keyboard shortcuts

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