codes

package
v0.0.0-...-40e4417 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2017 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrRaftDuplicateGroupID = &codeError{
		code:  pb.ResultCode_ResultCodeRaftDuplicateGroupID,
		cause: errors.New("raft: duplicate group id"),
	}
)

Err for data node management

Functions

func Code

func Code(err error) pb.ResultCode

Code return the code aliased to the error if any

func Result

func Result(err error) *pb.Result

Result turn err into rpc result

func WithCode

func WithCode(code pb.ResultCode, err error) error

WithCode alias a code to the error

Types

This section is empty.

Jump to

Keyboard shortcuts

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