errorspb

package
v1.2.4 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2019 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthErrors = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowErrors   = fmt.Errorf("proto: integer overflow")
)
View Source
var (
	ErrInvalidLengthHintdetail = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowHintdetail   = fmt.Errorf("proto: integer overflow")
)
View Source
var (
	ErrInvalidLengthMarkers = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowMarkers   = fmt.Errorf("proto: integer overflow")
)
View Source
var (
	ErrInvalidLengthTags = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowTags   = fmt.Errorf("proto: integer overflow")
)
View Source
var (
	ErrInvalidLengthTesting = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowTesting   = fmt.Errorf("proto: integer overflow")
)

Functions

This section is empty.

Types

type EncodedError

type EncodedError struct {
	// Types that are valid to be assigned to Error:
	//	*EncodedError_Leaf
	//	*EncodedError_Wrapper
	Error                isEncodedError_Error `protobuf_oneof:"error"`
	XXX_NoUnkeyedLiteral struct{}             `json:"-"`
	XXX_sizecache        int32                `json:"-"`
}

EncodedError is the wire-encodable representation of an error (or error cause chain).

func (*EncodedError) Descriptor

func (*EncodedError) Descriptor() ([]byte, []int)

func (*EncodedError) GetError

func (m *EncodedError) GetError() isEncodedError_Error

func (*EncodedError) GetLeaf

func (m *EncodedError) GetLeaf() *EncodedErrorLeaf

func (*EncodedError) GetWrapper

func (m *EncodedError) GetWrapper() *EncodedWrapper

func (*EncodedError) Marshal

func (m *EncodedError) Marshal() (dAtA []byte, err error)

func (*EncodedError) MarshalTo

func (m *EncodedError) MarshalTo(dAtA []byte) (int, error)

func (*EncodedError) ProtoMessage

func (*EncodedError) ProtoMessage()

func (*EncodedError) Reset

func (m *EncodedError) Reset()

func (*EncodedError) Size

func (m *EncodedError) Size() (n int)

func (*EncodedError) String

func (m *EncodedError) String() string

func (*EncodedError) Unmarshal

func (m *EncodedError) Unmarshal(dAtA []byte) error

func (*EncodedError) XXX_DiscardUnknown

func (m *EncodedError) XXX_DiscardUnknown()

func (*EncodedError) XXX_Marshal

func (m *EncodedError) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EncodedError) XXX_Merge

func (m *EncodedError) XXX_Merge(src proto.Message)

func (*EncodedError) XXX_OneofFuncs

func (*EncodedError) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

func (*EncodedError) XXX_Size

func (m *EncodedError) XXX_Size() int

func (*EncodedError) XXX_Unmarshal

func (m *EncodedError) XXX_Unmarshal(b []byte) error

type EncodedErrorDetails

type EncodedErrorDetails struct {
	// The original fully qualified error type name (mandatory).
	// This is primarily used to print out error details
	// in error reports and Format().
	//
	// It is additionally used to populate the error mark
	// below when the family name is not known/set.
	// See the `markers` error package and the
	// RFC on error handling for details.
	OriginalTypeName string `protobuf:"bytes,1,opt,name=original_type_name,json=originalTypeName,proto3" json:"original_type_name,omitempty"`
	// The error mark. This is used to determine error equivalence and
	// identifying a decode function.
	// See the `markers` error package and the
	// RFC on error handling for details.
	ErrorTypeMark ErrorTypeMark `protobuf:"bytes,2,opt,name=error_type_mark,json=errorTypeMark,proto3" json:"error_type_mark"`
	// The reportable payload (optional), which is as descriptive as
	// possible but may not contain PII.
	//
	// This is extracted automatically using a registered encoder, if
	// any, or the SafeDetailer interface.
	ReportablePayload []string `protobuf:"bytes,3,rep,name=reportable_payload,json=reportablePayload,proto3" json:"reportable_payload,omitempty"`
	// An arbitrary payload that (presumably) encodes the
	// native error object. This is also optional.
	//
	// This is extracted automatically using a registered encoder, if
	// any.
	FullDetails          *types.Any `protobuf:"bytes,4,opt,name=full_details,json=fullDetails,proto3" json:"full_details,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*EncodedErrorDetails) Descriptor

func (*EncodedErrorDetails) Descriptor() ([]byte, []int)

func (*EncodedErrorDetails) Marshal

func (m *EncodedErrorDetails) Marshal() (dAtA []byte, err error)

func (*EncodedErrorDetails) MarshalTo

func (m *EncodedErrorDetails) MarshalTo(dAtA []byte) (int, error)

func (*EncodedErrorDetails) ProtoMessage

func (*EncodedErrorDetails) ProtoMessage()

func (*EncodedErrorDetails) Reset

func (m *EncodedErrorDetails) Reset()

func (*EncodedErrorDetails) Size

func (m *EncodedErrorDetails) Size() (n int)

func (*EncodedErrorDetails) String

func (m *EncodedErrorDetails) String() string

func (*EncodedErrorDetails) Unmarshal

func (m *EncodedErrorDetails) Unmarshal(dAtA []byte) error

func (*EncodedErrorDetails) XXX_DiscardUnknown

func (m *EncodedErrorDetails) XXX_DiscardUnknown()

func (*EncodedErrorDetails) XXX_Marshal

func (m *EncodedErrorDetails) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EncodedErrorDetails) XXX_Merge

func (m *EncodedErrorDetails) XXX_Merge(src proto.Message)

func (*EncodedErrorDetails) XXX_Size

func (m *EncodedErrorDetails) XXX_Size() int

func (*EncodedErrorDetails) XXX_Unmarshal

func (m *EncodedErrorDetails) XXX_Unmarshal(b []byte) error

type EncodedErrorLeaf

type EncodedErrorLeaf struct {
	// The main error message (mandatory), that can be printed to human
	// users and may contain PII. This contains the value of the leaf
	// error's Error(), or using a registered encoder.
	Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	// The error details.
	Details              EncodedErrorDetails `protobuf:"bytes,2,opt,name=details,proto3" json:"details"`
	XXX_NoUnkeyedLiteral struct{}            `json:"-"`
	XXX_sizecache        int32               `json:"-"`
}

EncodedErrorLeaf is the wire-encodable representation of an error leaf.

func (*EncodedErrorLeaf) Descriptor

func (*EncodedErrorLeaf) Descriptor() ([]byte, []int)

func (*EncodedErrorLeaf) Marshal

func (m *EncodedErrorLeaf) Marshal() (dAtA []byte, err error)

func (*EncodedErrorLeaf) MarshalTo

func (m *EncodedErrorLeaf) MarshalTo(dAtA []byte) (int, error)

func (*EncodedErrorLeaf) ProtoMessage

func (*EncodedErrorLeaf) ProtoMessage()

func (*EncodedErrorLeaf) Reset

func (m *EncodedErrorLeaf) Reset()

func (*EncodedErrorLeaf) Size

func (m *EncodedErrorLeaf) Size() (n int)

func (*EncodedErrorLeaf) String

func (m *EncodedErrorLeaf) String() string

func (*EncodedErrorLeaf) Unmarshal

func (m *EncodedErrorLeaf) Unmarshal(dAtA []byte) error

func (*EncodedErrorLeaf) XXX_DiscardUnknown

func (m *EncodedErrorLeaf) XXX_DiscardUnknown()

func (*EncodedErrorLeaf) XXX_Marshal

func (m *EncodedErrorLeaf) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EncodedErrorLeaf) XXX_Merge

func (m *EncodedErrorLeaf) XXX_Merge(src proto.Message)

func (*EncodedErrorLeaf) XXX_Size

func (m *EncodedErrorLeaf) XXX_Size() int

func (*EncodedErrorLeaf) XXX_Unmarshal

func (m *EncodedErrorLeaf) XXX_Unmarshal(b []byte) error

type EncodedError_Leaf

type EncodedError_Leaf struct {
	Leaf *EncodedErrorLeaf `protobuf:"bytes,1,opt,name=leaf,proto3,oneof"`
}

func (*EncodedError_Leaf) MarshalTo

func (m *EncodedError_Leaf) MarshalTo(dAtA []byte) (int, error)

func (*EncodedError_Leaf) Size

func (m *EncodedError_Leaf) Size() (n int)

type EncodedError_Wrapper

type EncodedError_Wrapper struct {
	Wrapper *EncodedWrapper `protobuf:"bytes,2,opt,name=wrapper,proto3,oneof"`
}

func (*EncodedError_Wrapper) MarshalTo

func (m *EncodedError_Wrapper) MarshalTo(dAtA []byte) (int, error)

func (*EncodedError_Wrapper) Size

func (m *EncodedError_Wrapper) Size() (n int)

type EncodedWrapper

type EncodedWrapper struct {
	// The cause error. Mandatory.
	Cause EncodedError `protobuf:"bytes,1,opt,name=cause,proto3" json:"cause"`
	// The wrapper message prefix (which may be empty). This
	// isbprinted before the cause's own message when
	// constructing a full message. This may contain PII.
	//
	// This is extracted automatically:
	//
	// - for wrappers that have a registered encoder,
	// - otherwise, when the wrapper's Error() has its cause's Error() as suffix.
	MessagePrefix string `protobuf:"bytes,2,opt,name=message_prefix,json=messagePrefix,proto3" json:"message_prefix,omitempty"`
	// The error details.
	Details              EncodedErrorDetails `protobuf:"bytes,3,opt,name=details,proto3" json:"details"`
	XXX_NoUnkeyedLiteral struct{}            `json:"-"`
	XXX_sizecache        int32               `json:"-"`
}

EncodedWrapper is the wire-encodable representation of an error wrapper.

func (*EncodedWrapper) Descriptor

func (*EncodedWrapper) Descriptor() ([]byte, []int)

func (*EncodedWrapper) Marshal

func (m *EncodedWrapper) Marshal() (dAtA []byte, err error)

func (*EncodedWrapper) MarshalTo

func (m *EncodedWrapper) MarshalTo(dAtA []byte) (int, error)

func (*EncodedWrapper) ProtoMessage

func (*EncodedWrapper) ProtoMessage()

func (*EncodedWrapper) Reset

func (m *EncodedWrapper) Reset()

func (*EncodedWrapper) Size

func (m *EncodedWrapper) Size() (n int)

func (*EncodedWrapper) String

func (m *EncodedWrapper) String() string

func (*EncodedWrapper) Unmarshal

func (m *EncodedWrapper) Unmarshal(dAtA []byte) error

func (*EncodedWrapper) XXX_DiscardUnknown

func (m *EncodedWrapper) XXX_DiscardUnknown()

func (*EncodedWrapper) XXX_Marshal

func (m *EncodedWrapper) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EncodedWrapper) XXX_Merge

func (m *EncodedWrapper) XXX_Merge(src proto.Message)

func (*EncodedWrapper) XXX_Size

func (m *EncodedWrapper) XXX_Size() int

func (*EncodedWrapper) XXX_Unmarshal

func (m *EncodedWrapper) XXX_Unmarshal(b []byte) error

type ErrorTypeMark

type ErrorTypeMark struct {
	// The family name identifies the error type.
	// This is equal to original_type_name above in the common case, but
	// can be overridden when e.g. the package that defines the type
	// changes path.
	// This is the field also used for looking up a decode function.
	FamilyName string `protobuf:"bytes,1,opt,name=family_name,json=familyName,proto3" json:"family_name,omitempty"`
	// This marker string is used in combination with
	// the family name for the purpose of determining error equivalence.
	// This can be used to separate error instances that have the same type
	// into separate equivalence classes.
	// See the `markers` error package and the
	// RFC on error handling for details.
	Extension            string   `protobuf:"bytes,2,opt,name=extension,proto3" json:"extension,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

ErrorTypeMark identifies an error type for the purpose of determining error equivalences and looking up decoder functions.

func (*ErrorTypeMark) Descriptor

func (*ErrorTypeMark) Descriptor() ([]byte, []int)

func (ErrorTypeMark) Equals added in v1.1.1

func (m ErrorTypeMark) Equals(o ErrorTypeMark) bool

func (*ErrorTypeMark) Marshal

func (m *ErrorTypeMark) Marshal() (dAtA []byte, err error)

func (*ErrorTypeMark) MarshalTo

func (m *ErrorTypeMark) MarshalTo(dAtA []byte) (int, error)

func (*ErrorTypeMark) ProtoMessage

func (*ErrorTypeMark) ProtoMessage()

func (*ErrorTypeMark) Reset

func (m *ErrorTypeMark) Reset()

func (*ErrorTypeMark) Size

func (m *ErrorTypeMark) Size() (n int)

func (*ErrorTypeMark) String

func (m *ErrorTypeMark) String() string

func (*ErrorTypeMark) Unmarshal

func (m *ErrorTypeMark) Unmarshal(dAtA []byte) error

func (*ErrorTypeMark) XXX_DiscardUnknown

func (m *ErrorTypeMark) XXX_DiscardUnknown()

func (*ErrorTypeMark) XXX_Marshal

func (m *ErrorTypeMark) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ErrorTypeMark) XXX_Merge

func (m *ErrorTypeMark) XXX_Merge(src proto.Message)

func (*ErrorTypeMark) XXX_Size

func (m *ErrorTypeMark) XXX_Size() int

func (*ErrorTypeMark) XXX_Unmarshal

func (m *ErrorTypeMark) XXX_Unmarshal(b []byte) error

type MarkPayload

type MarkPayload struct {
	Msg                  string          `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
	Types                []ErrorTypeMark `protobuf:"bytes,2,rep,name=types,proto3" json:"types"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

MarkPayload is the error payload for a forced marker. See errors/markers/markers.go and the RFC on error handling for details.

func (*MarkPayload) Descriptor

func (*MarkPayload) Descriptor() ([]byte, []int)

func (*MarkPayload) Marshal

func (m *MarkPayload) Marshal() (dAtA []byte, err error)

func (*MarkPayload) MarshalTo

func (m *MarkPayload) MarshalTo(dAtA []byte) (int, error)

func (*MarkPayload) ProtoMessage

func (*MarkPayload) ProtoMessage()

func (*MarkPayload) Reset

func (m *MarkPayload) Reset()

func (*MarkPayload) Size

func (m *MarkPayload) Size() (n int)

func (*MarkPayload) String

func (m *MarkPayload) String() string

func (*MarkPayload) Unmarshal

func (m *MarkPayload) Unmarshal(dAtA []byte) error

func (*MarkPayload) XXX_DiscardUnknown

func (m *MarkPayload) XXX_DiscardUnknown()

func (*MarkPayload) XXX_Marshal

func (m *MarkPayload) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MarkPayload) XXX_Merge

func (m *MarkPayload) XXX_Merge(src proto.Message)

func (*MarkPayload) XXX_Size

func (m *MarkPayload) XXX_Size() int

func (*MarkPayload) XXX_Unmarshal

func (m *MarkPayload) XXX_Unmarshal(b []byte) error

type StringPayload

type StringPayload struct {
	Msg                  string   `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*StringPayload) Descriptor

func (*StringPayload) Descriptor() ([]byte, []int)

func (*StringPayload) Marshal

func (m *StringPayload) Marshal() (dAtA []byte, err error)

func (*StringPayload) MarshalTo

func (m *StringPayload) MarshalTo(dAtA []byte) (int, error)

func (*StringPayload) ProtoMessage

func (*StringPayload) ProtoMessage()

func (*StringPayload) Reset

func (m *StringPayload) Reset()

func (*StringPayload) Size

func (m *StringPayload) Size() (n int)

func (*StringPayload) String

func (m *StringPayload) String() string

func (*StringPayload) Unmarshal

func (m *StringPayload) Unmarshal(dAtA []byte) error

func (*StringPayload) XXX_DiscardUnknown

func (m *StringPayload) XXX_DiscardUnknown()

func (*StringPayload) XXX_Marshal

func (m *StringPayload) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*StringPayload) XXX_Merge

func (m *StringPayload) XXX_Merge(src proto.Message)

func (*StringPayload) XXX_Size

func (m *StringPayload) XXX_Size() int

func (*StringPayload) XXX_Unmarshal

func (m *StringPayload) XXX_Unmarshal(b []byte) error

type TagPayload added in v1.1.1

type TagPayload struct {
	Tag                  string   `protobuf:"bytes,1,opt,name=tag,proto3" json:"tag,omitempty"`
	Value                string   `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*TagPayload) Descriptor added in v1.1.1

func (*TagPayload) Descriptor() ([]byte, []int)

func (*TagPayload) Marshal added in v1.1.1

func (m *TagPayload) Marshal() (dAtA []byte, err error)

func (*TagPayload) MarshalTo added in v1.1.1

func (m *TagPayload) MarshalTo(dAtA []byte) (int, error)

func (*TagPayload) ProtoMessage added in v1.1.1

func (*TagPayload) ProtoMessage()

func (*TagPayload) Reset added in v1.1.1

func (m *TagPayload) Reset()

func (*TagPayload) Size added in v1.1.1

func (m *TagPayload) Size() (n int)

func (*TagPayload) String added in v1.1.1

func (m *TagPayload) String() string

func (*TagPayload) Unmarshal added in v1.1.1

func (m *TagPayload) Unmarshal(dAtA []byte) error

func (*TagPayload) XXX_DiscardUnknown added in v1.1.1

func (m *TagPayload) XXX_DiscardUnknown()

func (*TagPayload) XXX_Marshal added in v1.1.1

func (m *TagPayload) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TagPayload) XXX_Merge added in v1.1.1

func (m *TagPayload) XXX_Merge(src proto.Message)

func (*TagPayload) XXX_Size added in v1.1.1

func (m *TagPayload) XXX_Size() int

func (*TagPayload) XXX_Unmarshal added in v1.1.1

func (m *TagPayload) XXX_Unmarshal(b []byte) error

type TagsPayload added in v1.1.1

type TagsPayload struct {
	Tags                 []TagPayload `protobuf:"bytes,1,rep,name=tags,proto3" json:"tags"`
	XXX_NoUnkeyedLiteral struct{}     `json:"-"`
	XXX_sizecache        int32        `json:"-"`
}

TagsPayload is the error payload for a WithContext marker. See errors/contexttags/withcontext.go and the RFC on error handling for details.

func (*TagsPayload) Descriptor added in v1.1.1

func (*TagsPayload) Descriptor() ([]byte, []int)

func (*TagsPayload) Marshal added in v1.1.1

func (m *TagsPayload) Marshal() (dAtA []byte, err error)

func (*TagsPayload) MarshalTo added in v1.1.1

func (m *TagsPayload) MarshalTo(dAtA []byte) (int, error)

func (*TagsPayload) ProtoMessage added in v1.1.1

func (*TagsPayload) ProtoMessage()

func (*TagsPayload) Reset added in v1.1.1

func (m *TagsPayload) Reset()

func (*TagsPayload) Size added in v1.1.1

func (m *TagsPayload) Size() (n int)

func (*TagsPayload) String added in v1.1.1

func (m *TagsPayload) String() string

func (*TagsPayload) Unmarshal added in v1.1.1

func (m *TagsPayload) Unmarshal(dAtA []byte) error

func (*TagsPayload) XXX_DiscardUnknown added in v1.1.1

func (m *TagsPayload) XXX_DiscardUnknown()

func (*TagsPayload) XXX_Marshal added in v1.1.1

func (m *TagsPayload) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TagsPayload) XXX_Merge added in v1.1.1

func (m *TagsPayload) XXX_Merge(src proto.Message)

func (*TagsPayload) XXX_Size added in v1.1.1

func (m *TagsPayload) XXX_Size() int

func (*TagsPayload) XXX_Unmarshal added in v1.1.1

func (m *TagsPayload) XXX_Unmarshal(b []byte) error

type TestError

type TestError struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

TestError is meant for use in testing only.

func (*TestError) Descriptor

func (*TestError) Descriptor() ([]byte, []int)

func (*TestError) Error

func (t *TestError) Error() string

Error implements the error interface.

func (*TestError) Marshal

func (m *TestError) Marshal() (dAtA []byte, err error)

func (*TestError) MarshalTo

func (m *TestError) MarshalTo(dAtA []byte) (int, error)

func (*TestError) ProtoMessage

func (*TestError) ProtoMessage()

func (*TestError) Reset

func (m *TestError) Reset()

func (*TestError) Size

func (m *TestError) Size() (n int)

func (*TestError) String

func (m *TestError) String() string

func (*TestError) Unmarshal

func (m *TestError) Unmarshal(dAtA []byte) error

func (*TestError) XXX_DiscardUnknown

func (m *TestError) XXX_DiscardUnknown()

func (*TestError) XXX_Marshal

func (m *TestError) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TestError) XXX_Merge

func (m *TestError) XXX_Merge(src proto.Message)

func (*TestError) XXX_Size

func (m *TestError) XXX_Size() int

func (*TestError) XXX_Unmarshal

func (m *TestError) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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