Files
EasyTier/easytier-go/proto/error/error.pb.go
T
Luna YaoandClaude Code 250c2ad8d6 refactor(config): preserve explicit flags with FlagsPatch and derive CLI arguments from schema (#2585)
This PR refactors EasyTier's configuration flags system across protobuf definitions, TOML/API persistence, runtime reconciliation, and the CLI.

It introduces a synthesized FlagsPatch protobuf message with optionize and pbjson support to track field presence reliably, replaces manual CLI flag boilerplate with dynamic schema-driven clap argument generation, and
establishes Flags::resolve(patch) as the single source of truth for runtime defaults.

Co-authored-by: Claude Code <noreply@anthropic.com>
2026-10-10 22:11:08 +08:00

653 lines
18 KiB
Go

// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.36.11
// protoc v7.36.1
// source: error.proto
package error
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
sync "sync"
unsafe "unsafe"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type OtherError struct {
state protoimpl.MessageState `protogen:"open.v1"`
ErrorMessage string `protobuf:"bytes,1,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *OtherError) Reset() {
*x = OtherError{}
mi := &file_error_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *OtherError) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*OtherError) ProtoMessage() {}
func (x *OtherError) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[0]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use OtherError.ProtoReflect.Descriptor instead.
func (*OtherError) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{0}
}
func (x *OtherError) GetErrorMessage() string {
if x != nil {
return x.ErrorMessage
}
return ""
}
type InvalidMethodIndex struct {
state protoimpl.MessageState `protogen:"open.v1"`
ServiceName string `protobuf:"bytes,1,opt,name=service_name,json=serviceName,proto3" json:"service_name,omitempty"`
MethodIndex uint32 `protobuf:"varint,2,opt,name=method_index,json=methodIndex,proto3" json:"method_index,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *InvalidMethodIndex) Reset() {
*x = InvalidMethodIndex{}
mi := &file_error_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *InvalidMethodIndex) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*InvalidMethodIndex) ProtoMessage() {}
func (x *InvalidMethodIndex) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[1]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use InvalidMethodIndex.ProtoReflect.Descriptor instead.
func (*InvalidMethodIndex) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{1}
}
func (x *InvalidMethodIndex) GetServiceName() string {
if x != nil {
return x.ServiceName
}
return ""
}
func (x *InvalidMethodIndex) GetMethodIndex() uint32 {
if x != nil {
return x.MethodIndex
}
return 0
}
type InvalidService struct {
state protoimpl.MessageState `protogen:"open.v1"`
ServiceName string `protobuf:"bytes,1,opt,name=service_name,json=serviceName,proto3" json:"service_name,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *InvalidService) Reset() {
*x = InvalidService{}
mi := &file_error_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *InvalidService) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*InvalidService) ProtoMessage() {}
func (x *InvalidService) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[2]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use InvalidService.ProtoReflect.Descriptor instead.
func (*InvalidService) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{2}
}
func (x *InvalidService) GetServiceName() string {
if x != nil {
return x.ServiceName
}
return ""
}
type ProstDecodeError struct {
state protoimpl.MessageState `protogen:"open.v1"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *ProstDecodeError) Reset() {
*x = ProstDecodeError{}
mi := &file_error_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *ProstDecodeError) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ProstDecodeError) ProtoMessage() {}
func (x *ProstDecodeError) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[3]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ProstDecodeError.ProtoReflect.Descriptor instead.
func (*ProstDecodeError) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{3}
}
type ProstEncodeError struct {
state protoimpl.MessageState `protogen:"open.v1"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *ProstEncodeError) Reset() {
*x = ProstEncodeError{}
mi := &file_error_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *ProstEncodeError) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ProstEncodeError) ProtoMessage() {}
func (x *ProstEncodeError) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[4]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ProstEncodeError.ProtoReflect.Descriptor instead.
func (*ProstEncodeError) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{4}
}
type ExecuteError struct {
state protoimpl.MessageState `protogen:"open.v1"`
ErrorMessage string `protobuf:"bytes,1,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *ExecuteError) Reset() {
*x = ExecuteError{}
mi := &file_error_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *ExecuteError) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ExecuteError) ProtoMessage() {}
func (x *ExecuteError) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[5]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ExecuteError.ProtoReflect.Descriptor instead.
func (*ExecuteError) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{5}
}
func (x *ExecuteError) GetErrorMessage() string {
if x != nil {
return x.ErrorMessage
}
return ""
}
type MalformatRpcPacket struct {
state protoimpl.MessageState `protogen:"open.v1"`
ErrorMessage string `protobuf:"bytes,1,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *MalformatRpcPacket) Reset() {
*x = MalformatRpcPacket{}
mi := &file_error_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *MalformatRpcPacket) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*MalformatRpcPacket) ProtoMessage() {}
func (x *MalformatRpcPacket) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[6]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use MalformatRpcPacket.ProtoReflect.Descriptor instead.
func (*MalformatRpcPacket) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{6}
}
func (x *MalformatRpcPacket) GetErrorMessage() string {
if x != nil {
return x.ErrorMessage
}
return ""
}
type Timeout struct {
state protoimpl.MessageState `protogen:"open.v1"`
ErrorMessage string `protobuf:"bytes,1,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *Timeout) Reset() {
*x = Timeout{}
mi := &file_error_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *Timeout) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Timeout) ProtoMessage() {}
func (x *Timeout) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[7]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use Timeout.ProtoReflect.Descriptor instead.
func (*Timeout) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{7}
}
func (x *Timeout) GetErrorMessage() string {
if x != nil {
return x.ErrorMessage
}
return ""
}
type Error struct {
state protoimpl.MessageState `protogen:"open.v1"`
// Types that are valid to be assigned to ErrorKind:
//
// *Error_OtherError
// *Error_InvalidMethodIndex
// *Error_InvalidService
// *Error_ProstDecodeError
// *Error_ProstEncodeError
// *Error_ExecuteError
// *Error_MalformatRpcPacket
// *Error_Timeout
ErrorKind isError_ErrorKind `protobuf_oneof:"error_kind"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *Error) Reset() {
*x = Error{}
mi := &file_error_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *Error) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Error) ProtoMessage() {}
func (x *Error) ProtoReflect() protoreflect.Message {
mi := &file_error_proto_msgTypes[8]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use Error.ProtoReflect.Descriptor instead.
func (*Error) Descriptor() ([]byte, []int) {
return file_error_proto_rawDescGZIP(), []int{8}
}
func (x *Error) GetErrorKind() isError_ErrorKind {
if x != nil {
return x.ErrorKind
}
return nil
}
func (x *Error) GetOtherError() *OtherError {
if x != nil {
if x, ok := x.ErrorKind.(*Error_OtherError); ok {
return x.OtherError
}
}
return nil
}
func (x *Error) GetInvalidMethodIndex() *InvalidMethodIndex {
if x != nil {
if x, ok := x.ErrorKind.(*Error_InvalidMethodIndex); ok {
return x.InvalidMethodIndex
}
}
return nil
}
func (x *Error) GetInvalidService() *InvalidService {
if x != nil {
if x, ok := x.ErrorKind.(*Error_InvalidService); ok {
return x.InvalidService
}
}
return nil
}
func (x *Error) GetProstDecodeError() *ProstDecodeError {
if x != nil {
if x, ok := x.ErrorKind.(*Error_ProstDecodeError); ok {
return x.ProstDecodeError
}
}
return nil
}
func (x *Error) GetProstEncodeError() *ProstEncodeError {
if x != nil {
if x, ok := x.ErrorKind.(*Error_ProstEncodeError); ok {
return x.ProstEncodeError
}
}
return nil
}
func (x *Error) GetExecuteError() *ExecuteError {
if x != nil {
if x, ok := x.ErrorKind.(*Error_ExecuteError); ok {
return x.ExecuteError
}
}
return nil
}
func (x *Error) GetMalformatRpcPacket() *MalformatRpcPacket {
if x != nil {
if x, ok := x.ErrorKind.(*Error_MalformatRpcPacket); ok {
return x.MalformatRpcPacket
}
}
return nil
}
func (x *Error) GetTimeout() *Timeout {
if x != nil {
if x, ok := x.ErrorKind.(*Error_Timeout); ok {
return x.Timeout
}
}
return nil
}
type isError_ErrorKind interface {
isError_ErrorKind()
}
type Error_OtherError struct {
OtherError *OtherError `protobuf:"bytes,1,opt,name=other_error,json=otherError,proto3,oneof"`
}
type Error_InvalidMethodIndex struct {
InvalidMethodIndex *InvalidMethodIndex `protobuf:"bytes,2,opt,name=invalid_method_index,json=invalidMethodIndex,proto3,oneof"`
}
type Error_InvalidService struct {
InvalidService *InvalidService `protobuf:"bytes,3,opt,name=invalid_service,json=invalidService,proto3,oneof"`
}
type Error_ProstDecodeError struct {
ProstDecodeError *ProstDecodeError `protobuf:"bytes,4,opt,name=prost_decode_error,json=prostDecodeError,proto3,oneof"`
}
type Error_ProstEncodeError struct {
ProstEncodeError *ProstEncodeError `protobuf:"bytes,5,opt,name=prost_encode_error,json=prostEncodeError,proto3,oneof"`
}
type Error_ExecuteError struct {
ExecuteError *ExecuteError `protobuf:"bytes,6,opt,name=execute_error,json=executeError,proto3,oneof"`
}
type Error_MalformatRpcPacket struct {
MalformatRpcPacket *MalformatRpcPacket `protobuf:"bytes,7,opt,name=malformat_rpc_packet,json=malformatRpcPacket,proto3,oneof"`
}
type Error_Timeout struct {
Timeout *Timeout `protobuf:"bytes,8,opt,name=timeout,proto3,oneof"`
}
func (*Error_OtherError) isError_ErrorKind() {}
func (*Error_InvalidMethodIndex) isError_ErrorKind() {}
func (*Error_InvalidService) isError_ErrorKind() {}
func (*Error_ProstDecodeError) isError_ErrorKind() {}
func (*Error_ProstEncodeError) isError_ErrorKind() {}
func (*Error_ExecuteError) isError_ErrorKind() {}
func (*Error_MalformatRpcPacket) isError_ErrorKind() {}
func (*Error_Timeout) isError_ErrorKind() {}
var File_error_proto protoreflect.FileDescriptor
const file_error_proto_rawDesc = "" +
"\n" +
"\verror.proto\x12\x05error\"1\n" +
"\n" +
"OtherError\x12#\n" +
"\rerror_message\x18\x01 \x01(\tR\ferrorMessage\"Z\n" +
"\x12InvalidMethodIndex\x12!\n" +
"\fservice_name\x18\x01 \x01(\tR\vserviceName\x12!\n" +
"\fmethod_index\x18\x02 \x01(\rR\vmethodIndex\"3\n" +
"\x0eInvalidService\x12!\n" +
"\fservice_name\x18\x01 \x01(\tR\vserviceName\"\x12\n" +
"\x10ProstDecodeError\"\x12\n" +
"\x10ProstEncodeError\"3\n" +
"\fExecuteError\x12#\n" +
"\rerror_message\x18\x01 \x01(\tR\ferrorMessage\"9\n" +
"\x12MalformatRpcPacket\x12#\n" +
"\rerror_message\x18\x01 \x01(\tR\ferrorMessage\".\n" +
"\aTimeout\x12#\n" +
"\rerror_message\x18\x01 \x01(\tR\ferrorMessage\"\xa5\x04\n" +
"\x05Error\x124\n" +
"\vother_error\x18\x01 \x01(\v2\x11.error.OtherErrorH\x00R\n" +
"otherError\x12M\n" +
"\x14invalid_method_index\x18\x02 \x01(\v2\x19.error.InvalidMethodIndexH\x00R\x12invalidMethodIndex\x12@\n" +
"\x0finvalid_service\x18\x03 \x01(\v2\x15.error.InvalidServiceH\x00R\x0einvalidService\x12G\n" +
"\x12prost_decode_error\x18\x04 \x01(\v2\x17.error.ProstDecodeErrorH\x00R\x10prostDecodeError\x12G\n" +
"\x12prost_encode_error\x18\x05 \x01(\v2\x17.error.ProstEncodeErrorH\x00R\x10prostEncodeError\x12:\n" +
"\rexecute_error\x18\x06 \x01(\v2\x13.error.ExecuteErrorH\x00R\fexecuteError\x12M\n" +
"\x14malformat_rpc_packet\x18\a \x01(\v2\x19.error.MalformatRpcPacketH\x00R\x12malformatRpcPacket\x12*\n" +
"\atimeout\x18\b \x01(\v2\x0e.error.TimeoutH\x00R\atimeoutB\f\n" +
"\n" +
"error_kindb\x06proto3"
var (
file_error_proto_rawDescOnce sync.Once
file_error_proto_rawDescData []byte
)
func file_error_proto_rawDescGZIP() []byte {
file_error_proto_rawDescOnce.Do(func() {
file_error_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_error_proto_rawDesc), len(file_error_proto_rawDesc)))
})
return file_error_proto_rawDescData
}
var file_error_proto_msgTypes = make([]protoimpl.MessageInfo, 9)
var file_error_proto_goTypes = []any{
(*OtherError)(nil), // 0: error.OtherError
(*InvalidMethodIndex)(nil), // 1: error.InvalidMethodIndex
(*InvalidService)(nil), // 2: error.InvalidService
(*ProstDecodeError)(nil), // 3: error.ProstDecodeError
(*ProstEncodeError)(nil), // 4: error.ProstEncodeError
(*ExecuteError)(nil), // 5: error.ExecuteError
(*MalformatRpcPacket)(nil), // 6: error.MalformatRpcPacket
(*Timeout)(nil), // 7: error.Timeout
(*Error)(nil), // 8: error.Error
}
var file_error_proto_depIdxs = []int32{
0, // 0: error.Error.other_error:type_name -> error.OtherError
1, // 1: error.Error.invalid_method_index:type_name -> error.InvalidMethodIndex
2, // 2: error.Error.invalid_service:type_name -> error.InvalidService
3, // 3: error.Error.prost_decode_error:type_name -> error.ProstDecodeError
4, // 4: error.Error.prost_encode_error:type_name -> error.ProstEncodeError
5, // 5: error.Error.execute_error:type_name -> error.ExecuteError
6, // 6: error.Error.malformat_rpc_packet:type_name -> error.MalformatRpcPacket
7, // 7: error.Error.timeout:type_name -> error.Timeout
8, // [8:8] is the sub-list for method output_type
8, // [8:8] is the sub-list for method input_type
8, // [8:8] is the sub-list for extension type_name
8, // [8:8] is the sub-list for extension extendee
0, // [0:8] is the sub-list for field type_name
}
func init() { file_error_proto_init() }
func file_error_proto_init() {
if File_error_proto != nil {
return
}
file_error_proto_msgTypes[8].OneofWrappers = []any{
(*Error_OtherError)(nil),
(*Error_InvalidMethodIndex)(nil),
(*Error_InvalidService)(nil),
(*Error_ProstDecodeError)(nil),
(*Error_ProstEncodeError)(nil),
(*Error_ExecuteError)(nil),
(*Error_MalformatRpcPacket)(nil),
(*Error_Timeout)(nil),
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: unsafe.Slice(unsafe.StringData(file_error_proto_rawDesc), len(file_error_proto_rawDesc)),
NumEnums: 0,
NumMessages: 9,
NumExtensions: 0,
NumServices: 0,
},
GoTypes: file_error_proto_goTypes,
DependencyIndexes: file_error_proto_depIdxs,
MessageInfos: file_error_proto_msgTypes,
}.Build()
File_error_proto = out.File
file_error_proto_goTypes = nil
file_error_proto_depIdxs = nil
}