Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Error ¶
func Error(code StatusCode, msg string) error
Error wraps the message with a status code into an error.
func Errorf ¶
func Errorf(code StatusCode, format string, a ...interface{}) error
Errorf : Error :: fmt.Sprintf : fmt.Sprint
Types ¶
type StatusCode ¶
type StatusCode uint64
StatusCode is the type of status codes for drpc.
const ( Unknown StatusCode = iota OK Canceled InvalidArgument DeadlineExceeded NotFound AlreadyExists PermissionDenied ResourceExhausted FailedPrecondition Aborted OutOfRange Unimplemented Internal DataLoss Unauthenticated )
These constants are all the rpc error codes.
Click to show internal directories.
Click to hide internal directories.