github.com/microsoft/moc@v0.17.1/rpc/common/admin/moc_common_recovery.pb.go (about) 1 // Code generated by protoc-gen-go. DO NOT EDIT. 2 // source: admin/recovery/moc_common_recovery.proto 3 4 package admin 5 6 import ( 7 context "context" 8 fmt "fmt" 9 proto "github.com/golang/protobuf/proto" 10 wrappers "github.com/golang/protobuf/ptypes/wrappers" 11 grpc "google.golang.org/grpc" 12 codes "google.golang.org/grpc/codes" 13 status "google.golang.org/grpc/status" 14 math "math" 15 ) 16 17 // Reference imports to suppress errors if they are not otherwise used. 18 var _ = proto.Marshal 19 var _ = fmt.Errorf 20 var _ = math.Inf 21 22 // This is a compile-time assertion to ensure that this generated file 23 // is compatible with the proto package it is being compiled against. 24 // A compilation error at this line likely means your copy of the 25 // proto package needs to be updated. 26 const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package 27 28 type Operation int32 29 30 const ( 31 Operation_BACKUP Operation = 0 32 Operation_RESTORE Operation = 1 33 ) 34 35 var Operation_name = map[int32]string{ 36 0: "BACKUP", 37 1: "RESTORE", 38 } 39 40 var Operation_value = map[string]int32{ 41 "BACKUP": 0, 42 "RESTORE": 1, 43 } 44 45 func (x Operation) String() string { 46 return proto.EnumName(Operation_name, int32(x)) 47 } 48 49 func (Operation) EnumDescriptor() ([]byte, []int) { 50 return fileDescriptor_04605f1027235eab, []int{0} 51 } 52 53 type RecoveryRequest struct { 54 OperationType Operation `protobuf:"varint,1,opt,name=OperationType,proto3,enum=moc.common.admin.Operation" json:"OperationType,omitempty"` 55 // Path to back to or restore from. Can be a relative path for registry 56 Path string `protobuf:"bytes,2,opt,name=Path,proto3" json:"Path,omitempty"` 57 // Config file path. Must be on hard disk. 58 ConfigFilePath string `protobuf:"bytes,3,opt,name=ConfigFilePath,proto3" json:"ConfigFilePath,omitempty"` 59 // Type of data store 60 StoreType string `protobuf:"bytes,4,opt,name=StoreType,proto3" json:"StoreType,omitempty"` 61 XXX_NoUnkeyedLiteral struct{} `json:"-"` 62 XXX_unrecognized []byte `json:"-"` 63 XXX_sizecache int32 `json:"-"` 64 } 65 66 func (m *RecoveryRequest) Reset() { *m = RecoveryRequest{} } 67 func (m *RecoveryRequest) String() string { return proto.CompactTextString(m) } 68 func (*RecoveryRequest) ProtoMessage() {} 69 func (*RecoveryRequest) Descriptor() ([]byte, []int) { 70 return fileDescriptor_04605f1027235eab, []int{0} 71 } 72 73 func (m *RecoveryRequest) XXX_Unmarshal(b []byte) error { 74 return xxx_messageInfo_RecoveryRequest.Unmarshal(m, b) 75 } 76 func (m *RecoveryRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 77 return xxx_messageInfo_RecoveryRequest.Marshal(b, m, deterministic) 78 } 79 func (m *RecoveryRequest) XXX_Merge(src proto.Message) { 80 xxx_messageInfo_RecoveryRequest.Merge(m, src) 81 } 82 func (m *RecoveryRequest) XXX_Size() int { 83 return xxx_messageInfo_RecoveryRequest.Size(m) 84 } 85 func (m *RecoveryRequest) XXX_DiscardUnknown() { 86 xxx_messageInfo_RecoveryRequest.DiscardUnknown(m) 87 } 88 89 var xxx_messageInfo_RecoveryRequest proto.InternalMessageInfo 90 91 func (m *RecoveryRequest) GetOperationType() Operation { 92 if m != nil { 93 return m.OperationType 94 } 95 return Operation_BACKUP 96 } 97 98 func (m *RecoveryRequest) GetPath() string { 99 if m != nil { 100 return m.Path 101 } 102 return "" 103 } 104 105 func (m *RecoveryRequest) GetConfigFilePath() string { 106 if m != nil { 107 return m.ConfigFilePath 108 } 109 return "" 110 } 111 112 func (m *RecoveryRequest) GetStoreType() string { 113 if m != nil { 114 return m.StoreType 115 } 116 return "" 117 } 118 119 type RecoveryResponse struct { 120 Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` 121 Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` 122 XXX_NoUnkeyedLiteral struct{} `json:"-"` 123 XXX_unrecognized []byte `json:"-"` 124 XXX_sizecache int32 `json:"-"` 125 } 126 127 func (m *RecoveryResponse) Reset() { *m = RecoveryResponse{} } 128 func (m *RecoveryResponse) String() string { return proto.CompactTextString(m) } 129 func (*RecoveryResponse) ProtoMessage() {} 130 func (*RecoveryResponse) Descriptor() ([]byte, []int) { 131 return fileDescriptor_04605f1027235eab, []int{1} 132 } 133 134 func (m *RecoveryResponse) XXX_Unmarshal(b []byte) error { 135 return xxx_messageInfo_RecoveryResponse.Unmarshal(m, b) 136 } 137 func (m *RecoveryResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 138 return xxx_messageInfo_RecoveryResponse.Marshal(b, m, deterministic) 139 } 140 func (m *RecoveryResponse) XXX_Merge(src proto.Message) { 141 xxx_messageInfo_RecoveryResponse.Merge(m, src) 142 } 143 func (m *RecoveryResponse) XXX_Size() int { 144 return xxx_messageInfo_RecoveryResponse.Size(m) 145 } 146 func (m *RecoveryResponse) XXX_DiscardUnknown() { 147 xxx_messageInfo_RecoveryResponse.DiscardUnknown(m) 148 } 149 150 var xxx_messageInfo_RecoveryResponse proto.InternalMessageInfo 151 152 func (m *RecoveryResponse) GetResult() *wrappers.BoolValue { 153 if m != nil { 154 return m.Result 155 } 156 return nil 157 } 158 159 func (m *RecoveryResponse) GetError() string { 160 if m != nil { 161 return m.Error 162 } 163 return "" 164 } 165 166 func init() { 167 proto.RegisterEnum("moc.common.admin.Operation", Operation_name, Operation_value) 168 proto.RegisterType((*RecoveryRequest)(nil), "moc.common.admin.RecoveryRequest") 169 proto.RegisterType((*RecoveryResponse)(nil), "moc.common.admin.RecoveryResponse") 170 } 171 172 func init() { 173 proto.RegisterFile("admin/recovery/moc_common_recovery.proto", fileDescriptor_04605f1027235eab) 174 } 175 176 var fileDescriptor_04605f1027235eab = []byte{ 177 // 347 bytes of a gzipped FileDescriptorProto 178 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x51, 0xdd, 0x6a, 0xe2, 0x40, 179 0x14, 0x36, 0xbb, 0x6e, 0x16, 0x8f, 0xe8, 0x86, 0x61, 0x2f, 0xc4, 0x5d, 0x16, 0x37, 0x2c, 0x8b, 180 0xbb, 0x85, 0x19, 0x48, 0x9f, 0x40, 0xc5, 0x42, 0xe9, 0x85, 0x76, 0xb4, 0xbd, 0x28, 0x05, 0x49, 181 0xd2, 0x63, 0x0c, 0x4d, 0x72, 0xd2, 0xc9, 0xc4, 0xe2, 0x4b, 0xf5, 0x19, 0x8b, 0x13, 0x7f, 0xa8, 182 0x85, 0xde, 0x25, 0xdf, 0xcf, 0x39, 0xdf, 0x77, 0x06, 0xfa, 0xfe, 0x43, 0x1a, 0x67, 0x42, 0x61, 183 0x48, 0x6b, 0x54, 0x1b, 0x91, 0x52, 0xb8, 0x08, 0x29, 0x4d, 0x29, 0x5b, 0xec, 0x31, 0x9e, 0x2b, 184 0xd2, 0xc4, 0x9c, 0x94, 0x42, 0x5e, 0x51, 0xdc, 0x98, 0xba, 0xbf, 0x22, 0xa2, 0x28, 0x41, 0x61, 185 0xf8, 0xa0, 0x5c, 0x8a, 0x67, 0xe5, 0xe7, 0x39, 0xaa, 0xa2, 0x72, 0xb8, 0x2f, 0x16, 0x7c, 0x93, 186 0xbb, 0x21, 0x12, 0x9f, 0x4a, 0x2c, 0x34, 0x1b, 0x40, 0x6b, 0x92, 0xa3, 0xf2, 0x75, 0x4c, 0xd9, 187 0x7c, 0x93, 0x63, 0xc7, 0xea, 0x59, 0xfd, 0xb6, 0xf7, 0x83, 0x9f, 0x4e, 0xe7, 0x07, 0x99, 0x7c, 188 0xeb, 0x60, 0x0c, 0xea, 0x53, 0x5f, 0xaf, 0x3a, 0x9f, 0x7a, 0x56, 0xbf, 0x21, 0xcd, 0x37, 0xfb, 189 0x0b, 0xed, 0x11, 0x65, 0xcb, 0x38, 0xba, 0x88, 0x13, 0x34, 0xec, 0x67, 0xc3, 0x9e, 0xa0, 0xec, 190 0x27, 0x34, 0x66, 0x9a, 0x14, 0x9a, 0xd5, 0x75, 0x23, 0x39, 0x02, 0xee, 0x3d, 0x38, 0xc7, 0xbc, 191 0x45, 0x4e, 0x59, 0x81, 0xcc, 0x03, 0x5b, 0x62, 0x51, 0x26, 0xda, 0xec, 0x6b, 0x7a, 0x5d, 0x5e, 192 0xb5, 0xe6, 0xfb, 0xd6, 0x7c, 0x48, 0x94, 0xdc, 0xfa, 0x49, 0x89, 0x72, 0xa7, 0x64, 0xdf, 0xe1, 193 0xcb, 0x58, 0x29, 0x52, 0xbb, 0x10, 0xd5, 0xcf, 0xff, 0x3f, 0xd0, 0x38, 0x14, 0x61, 0x00, 0xf6, 194 0x70, 0x30, 0xba, 0xba, 0x99, 0x3a, 0x35, 0xd6, 0x84, 0xaf, 0x72, 0x3c, 0x9b, 0x4f, 0xe4, 0xd8, 195 0xb1, 0xbc, 0x00, 0x5a, 0xfb, 0x0c, 0x83, 0x08, 0x33, 0xcd, 0xae, 0xc1, 0xbe, 0xcc, 0xd6, 0xf4, 196 0x88, 0xec, 0xf7, 0xfb, 0x23, 0x9d, 0x9c, 0xb7, 0xeb, 0x7e, 0x24, 0xa9, 0x1a, 0xb9, 0xb5, 0xe1, 197 0xd9, 0xdd, 0xbf, 0x28, 0xd6, 0xab, 0x32, 0xd8, 0x2a, 0x45, 0x1a, 0x87, 0x8a, 0x0a, 0x5a, 0xea, 198 0xed, 0xe3, 0x0b, 0x95, 0x87, 0xa2, 0xf2, 0x0b, 0xe3, 0x0f, 0x6c, 0x53, 0xf4, 0xfc, 0x35, 0x00, 199 0x00, 0xff, 0xff, 0x4c, 0x37, 0xfb, 0xf6, 0x2a, 0x02, 0x00, 0x00, 200 } 201 202 // Reference imports to suppress errors if they are not otherwise used. 203 var _ context.Context 204 var _ grpc.ClientConn 205 206 // This is a compile-time assertion to ensure that this generated file 207 // is compatible with the grpc package it is being compiled against. 208 const _ = grpc.SupportPackageIsVersion4 209 210 // RecoveryAgentClient is the client API for RecoveryAgent service. 211 // 212 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. 213 type RecoveryAgentClient interface { 214 Invoke(ctx context.Context, in *RecoveryRequest, opts ...grpc.CallOption) (*RecoveryResponse, error) 215 } 216 217 type recoveryAgentClient struct { 218 cc *grpc.ClientConn 219 } 220 221 func NewRecoveryAgentClient(cc *grpc.ClientConn) RecoveryAgentClient { 222 return &recoveryAgentClient{cc} 223 } 224 225 func (c *recoveryAgentClient) Invoke(ctx context.Context, in *RecoveryRequest, opts ...grpc.CallOption) (*RecoveryResponse, error) { 226 out := new(RecoveryResponse) 227 err := c.cc.Invoke(ctx, "/moc.common.admin.RecoveryAgent/Invoke", in, out, opts...) 228 if err != nil { 229 return nil, err 230 } 231 return out, nil 232 } 233 234 // RecoveryAgentServer is the server API for RecoveryAgent service. 235 type RecoveryAgentServer interface { 236 Invoke(context.Context, *RecoveryRequest) (*RecoveryResponse, error) 237 } 238 239 // UnimplementedRecoveryAgentServer can be embedded to have forward compatible implementations. 240 type UnimplementedRecoveryAgentServer struct { 241 } 242 243 func (*UnimplementedRecoveryAgentServer) Invoke(ctx context.Context, req *RecoveryRequest) (*RecoveryResponse, error) { 244 return nil, status.Errorf(codes.Unimplemented, "method Invoke not implemented") 245 } 246 247 func RegisterRecoveryAgentServer(s *grpc.Server, srv RecoveryAgentServer) { 248 s.RegisterService(&_RecoveryAgent_serviceDesc, srv) 249 } 250 251 func _RecoveryAgent_Invoke_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 252 in := new(RecoveryRequest) 253 if err := dec(in); err != nil { 254 return nil, err 255 } 256 if interceptor == nil { 257 return srv.(RecoveryAgentServer).Invoke(ctx, in) 258 } 259 info := &grpc.UnaryServerInfo{ 260 Server: srv, 261 FullMethod: "/moc.common.admin.RecoveryAgent/Invoke", 262 } 263 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 264 return srv.(RecoveryAgentServer).Invoke(ctx, req.(*RecoveryRequest)) 265 } 266 return interceptor(ctx, in, info, handler) 267 } 268 269 var _RecoveryAgent_serviceDesc = grpc.ServiceDesc{ 270 ServiceName: "moc.common.admin.RecoveryAgent", 271 HandlerType: (*RecoveryAgentServer)(nil), 272 Methods: []grpc.MethodDesc{ 273 { 274 MethodName: "Invoke", 275 Handler: _RecoveryAgent_Invoke_Handler, 276 }, 277 }, 278 Streams: []grpc.StreamDesc{}, 279 Metadata: "admin/recovery/moc_common_recovery.proto", 280 }