blob: f3ef3e66e3d263bb3a47e7dfe1215d2d8ffd8ff5 [file] [log] [blame]
Amit Ghosh09f28362020-06-12 21:52:19 +01001// Code generated by protoc-gen-go. DO NOT EDIT.
2// source: dmi/sw_management_service.proto
3
4package dmi
5
6import (
7 context "context"
8 fmt "fmt"
9 proto "github.com/golang/protobuf/proto"
10 grpc "google.golang.org/grpc"
11 math "math"
12)
13
14// Reference imports to suppress errors if they are not otherwise used.
15var _ = proto.Marshal
16var _ = fmt.Errorf
17var _ = math.Inf
18
19// This is a compile-time assertion to ensure that this generated file
20// is compatible with the proto package it is being compiled against.
21// A compilation error at this line likely means your copy of the
22// proto package needs to be updated.
23const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
24
25type SoftwareVersionInformation struct {
26 ActiveVersions []*ImageVersion `protobuf:"bytes,1,rep,name=active_versions,json=activeVersions,proto3" json:"active_versions,omitempty"`
27 StandbyVersions []*ImageVersion `protobuf:"bytes,2,rep,name=standby_versions,json=standbyVersions,proto3" json:"standby_versions,omitempty"`
28 XXX_NoUnkeyedLiteral struct{} `json:"-"`
29 XXX_unrecognized []byte `json:"-"`
30 XXX_sizecache int32 `json:"-"`
31}
32
33func (m *SoftwareVersionInformation) Reset() { *m = SoftwareVersionInformation{} }
34func (m *SoftwareVersionInformation) String() string { return proto.CompactTextString(m) }
35func (*SoftwareVersionInformation) ProtoMessage() {}
36func (*SoftwareVersionInformation) Descriptor() ([]byte, []int) {
37 return fileDescriptor_000929e4bec891d7, []int{0}
38}
39
40func (m *SoftwareVersionInformation) XXX_Unmarshal(b []byte) error {
41 return xxx_messageInfo_SoftwareVersionInformation.Unmarshal(m, b)
42}
43func (m *SoftwareVersionInformation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
44 return xxx_messageInfo_SoftwareVersionInformation.Marshal(b, m, deterministic)
45}
46func (m *SoftwareVersionInformation) XXX_Merge(src proto.Message) {
47 xxx_messageInfo_SoftwareVersionInformation.Merge(m, src)
48}
49func (m *SoftwareVersionInformation) XXX_Size() int {
50 return xxx_messageInfo_SoftwareVersionInformation.Size(m)
51}
52func (m *SoftwareVersionInformation) XXX_DiscardUnknown() {
53 xxx_messageInfo_SoftwareVersionInformation.DiscardUnknown(m)
54}
55
56var xxx_messageInfo_SoftwareVersionInformation proto.InternalMessageInfo
57
58func (m *SoftwareVersionInformation) GetActiveVersions() []*ImageVersion {
59 if m != nil {
60 return m.ActiveVersions
61 }
62 return nil
63}
64
65func (m *SoftwareVersionInformation) GetStandbyVersions() []*ImageVersion {
66 if m != nil {
67 return m.StandbyVersions
68 }
69 return nil
70}
71
aghoshc301dcd2020-09-03 16:55:34 +010072type GetSoftwareVersionInformationResponse struct {
73 Status Status `protobuf:"varint,1,opt,name=status,proto3,enum=dmi.Status" json:"status,omitempty"`
74 Reason Reason `protobuf:"varint,2,opt,name=reason,proto3,enum=dmi.Reason" json:"reason,omitempty"`
75 Info *SoftwareVersionInformation `protobuf:"bytes,3,opt,name=info,proto3" json:"info,omitempty"`
76 XXX_NoUnkeyedLiteral struct{} `json:"-"`
77 XXX_unrecognized []byte `json:"-"`
78 XXX_sizecache int32 `json:"-"`
79}
80
81func (m *GetSoftwareVersionInformationResponse) Reset() { *m = GetSoftwareVersionInformationResponse{} }
82func (m *GetSoftwareVersionInformationResponse) String() string { return proto.CompactTextString(m) }
83func (*GetSoftwareVersionInformationResponse) ProtoMessage() {}
84func (*GetSoftwareVersionInformationResponse) Descriptor() ([]byte, []int) {
85 return fileDescriptor_000929e4bec891d7, []int{1}
86}
87
88func (m *GetSoftwareVersionInformationResponse) XXX_Unmarshal(b []byte) error {
89 return xxx_messageInfo_GetSoftwareVersionInformationResponse.Unmarshal(m, b)
90}
91func (m *GetSoftwareVersionInformationResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
92 return xxx_messageInfo_GetSoftwareVersionInformationResponse.Marshal(b, m, deterministic)
93}
94func (m *GetSoftwareVersionInformationResponse) XXX_Merge(src proto.Message) {
95 xxx_messageInfo_GetSoftwareVersionInformationResponse.Merge(m, src)
96}
97func (m *GetSoftwareVersionInformationResponse) XXX_Size() int {
98 return xxx_messageInfo_GetSoftwareVersionInformationResponse.Size(m)
99}
100func (m *GetSoftwareVersionInformationResponse) XXX_DiscardUnknown() {
101 xxx_messageInfo_GetSoftwareVersionInformationResponse.DiscardUnknown(m)
102}
103
104var xxx_messageInfo_GetSoftwareVersionInformationResponse proto.InternalMessageInfo
105
106func (m *GetSoftwareVersionInformationResponse) GetStatus() Status {
107 if m != nil {
108 return m.Status
109 }
110 return Status_UNDEFINED_STATUS
111}
112
113func (m *GetSoftwareVersionInformationResponse) GetReason() Reason {
114 if m != nil {
115 return m.Reason
116 }
117 return Reason_UNDEFINED_REASON
118}
119
120func (m *GetSoftwareVersionInformationResponse) GetInfo() *SoftwareVersionInformation {
121 if m != nil {
122 return m.Info
123 }
124 return nil
125}
126
Amit Ghosh09f28362020-06-12 21:52:19 +0100127type DownloadImageRequest struct {
128 DeviceUuid *Uuid `protobuf:"bytes,1,opt,name=device_uuid,json=deviceUuid,proto3" json:"device_uuid,omitempty"`
129 ImageInfo *ImageInformation `protobuf:"bytes,2,opt,name=image_info,json=imageInfo,proto3" json:"image_info,omitempty"`
130 XXX_NoUnkeyedLiteral struct{} `json:"-"`
131 XXX_unrecognized []byte `json:"-"`
132 XXX_sizecache int32 `json:"-"`
133}
134
135func (m *DownloadImageRequest) Reset() { *m = DownloadImageRequest{} }
136func (m *DownloadImageRequest) String() string { return proto.CompactTextString(m) }
137func (*DownloadImageRequest) ProtoMessage() {}
138func (*DownloadImageRequest) Descriptor() ([]byte, []int) {
aghoshc301dcd2020-09-03 16:55:34 +0100139 return fileDescriptor_000929e4bec891d7, []int{2}
Amit Ghosh09f28362020-06-12 21:52:19 +0100140}
141
142func (m *DownloadImageRequest) XXX_Unmarshal(b []byte) error {
143 return xxx_messageInfo_DownloadImageRequest.Unmarshal(m, b)
144}
145func (m *DownloadImageRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
146 return xxx_messageInfo_DownloadImageRequest.Marshal(b, m, deterministic)
147}
148func (m *DownloadImageRequest) XXX_Merge(src proto.Message) {
149 xxx_messageInfo_DownloadImageRequest.Merge(m, src)
150}
151func (m *DownloadImageRequest) XXX_Size() int {
152 return xxx_messageInfo_DownloadImageRequest.Size(m)
153}
154func (m *DownloadImageRequest) XXX_DiscardUnknown() {
155 xxx_messageInfo_DownloadImageRequest.DiscardUnknown(m)
156}
157
158var xxx_messageInfo_DownloadImageRequest proto.InternalMessageInfo
159
160func (m *DownloadImageRequest) GetDeviceUuid() *Uuid {
161 if m != nil {
162 return m.DeviceUuid
163 }
164 return nil
165}
166
167func (m *DownloadImageRequest) GetImageInfo() *ImageInformation {
168 if m != nil {
169 return m.ImageInfo
170 }
171 return nil
172}
173
174func init() {
175 proto.RegisterType((*SoftwareVersionInformation)(nil), "dmi.SoftwareVersionInformation")
aghoshc301dcd2020-09-03 16:55:34 +0100176 proto.RegisterType((*GetSoftwareVersionInformationResponse)(nil), "dmi.GetSoftwareVersionInformationResponse")
Amit Ghosh09f28362020-06-12 21:52:19 +0100177 proto.RegisterType((*DownloadImageRequest)(nil), "dmi.DownloadImageRequest")
178}
179
180func init() { proto.RegisterFile("dmi/sw_management_service.proto", fileDescriptor_000929e4bec891d7) }
181
182var fileDescriptor_000929e4bec891d7 = []byte{
aghoshc301dcd2020-09-03 16:55:34 +0100183 // 458 bytes of a gzipped FileDescriptorProto
184 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x53, 0x5d, 0x6b, 0x13, 0x41,
185 0x14, 0x65, 0x13, 0x29, 0x74, 0xd6, 0x36, 0xed, 0x50, 0x21, 0xee, 0x4b, 0x4a, 0x44, 0x08, 0x85,
186 0x66, 0x65, 0xd3, 0x17, 0xad, 0x08, 0x4a, 0x41, 0xf3, 0xa0, 0xe0, 0x46, 0x7d, 0xf0, 0x65, 0x99,
187 0xec, 0xdc, 0xa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33, 0x1f, 0xd7, 0x28, 0x73, 0x5c, 0x81,
210 0xaa, 0x51, 0xf3, 0x3c, 0x4c, 0xe0, 0x7c, 0xfb, 0xac, 0xce, 0x85, 0xb2, 0xa0, 0x17, 0xac, 0x86,
211 0xbc, 0x9d, 0xe4, 0x4b, 0xcc, 0xb9, 0x14, 0xf3, 0x3d, 0xff, 0x52, 0x26, 0x7f, 0x03, 0x00, 0x00,
212 0xff, 0xff, 0x6d, 0x7d, 0x3b, 0xc8, 0x86, 0x03, 0x00, 0x00,
Amit Ghosh09f28362020-06-12 21:52:19 +0100213}
214
215// Reference imports to suppress errors if they are not otherwise used.
216var _ context.Context
217var _ grpc.ClientConn
218
219// This is a compile-time assertion to ensure that this generated file
220// is compatible with the grpc package it is being compiled against.
221const _ = grpc.SupportPackageIsVersion4
222
223// NativeSoftwareManagementServiceClient is the client API for NativeSoftwareManagementService service.
224//
225// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
226type NativeSoftwareManagementServiceClient interface {
227 // Get the software version information of the Active and Standby images
aghoshc301dcd2020-09-03 16:55:34 +0100228 GetSoftwareVersion(ctx context.Context, in *HardwareID, opts ...grpc.CallOption) (*GetSoftwareVersionInformationResponse, error)
Amit Ghosh09f28362020-06-12 21:52:19 +0100229 // Downloads and installs the image in the standby partition, returns the status/progress of the Install
230 DownloadImage(ctx context.Context, in *DownloadImageRequest, opts ...grpc.CallOption) (NativeSoftwareManagementService_DownloadImageClient, error)
231 // Activates and runs the OLT with the image in the standby partition. If things are fine this image will
232 // henceforth be marked as the Active Partition. The old working image would remain on the Standby partition.
233 // Any possibly required (sub-)steps like "commit" are left to the "Device Manager"
234 ActivateImage(ctx context.Context, in *HardwareID, opts ...grpc.CallOption) (NativeSoftwareManagementService_ActivateImageClient, error)
235 // Marks the image in the Standby as Active and reboots the device, so that it boots from that image which was in the standby.
aghoshc301dcd2020-09-03 16:55:34 +0100236 // This API is to be used if operator wants to go back to the previous software
Amit Ghosh09f28362020-06-12 21:52:19 +0100237 RevertToStandbyImage(ctx context.Context, in *HardwareID, opts ...grpc.CallOption) (NativeSoftwareManagementService_RevertToStandbyImageClient, error)
238}
239
240type nativeSoftwareManagementServiceClient struct {
241 cc *grpc.ClientConn
242}
243
244func NewNativeSoftwareManagementServiceClient(cc *grpc.ClientConn) NativeSoftwareManagementServiceClient {
245 return &nativeSoftwareManagementServiceClient{cc}
246}
247
aghoshc301dcd2020-09-03 16:55:34 +0100248func (c *nativeSoftwareManagementServiceClient) GetSoftwareVersion(ctx context.Context, in *HardwareID, opts ...grpc.CallOption) (*GetSoftwareVersionInformationResponse, error) {
249 out := new(GetSoftwareVersionInformationResponse)
Amit Ghosh09f28362020-06-12 21:52:19 +0100250 err := c.cc.Invoke(ctx, "/dmi.NativeSoftwareManagementService/GetSoftwareVersion", in, out, opts...)
251 if err != nil {
252 return nil, err
253 }
254 return out, nil
255}
256
257func (c *nativeSoftwareManagementServiceClient) DownloadImage(ctx context.Context, in *DownloadImageRequest, opts ...grpc.CallOption) (NativeSoftwareManagementService_DownloadImageClient, error) {
258 stream, err := c.cc.NewStream(ctx, &_NativeSoftwareManagementService_serviceDesc.Streams[0], "/dmi.NativeSoftwareManagementService/DownloadImage", opts...)
259 if err != nil {
260 return nil, err
261 }
262 x := &nativeSoftwareManagementServiceDownloadImageClient{stream}
263 if err := x.ClientStream.SendMsg(in); err != nil {
264 return nil, err
265 }
266 if err := x.ClientStream.CloseSend(); err != nil {
267 return nil, err
268 }
269 return x, nil
270}
271
272type NativeSoftwareManagementService_DownloadImageClient interface {
273 Recv() (*ImageStatus, error)
274 grpc.ClientStream
275}
276
277type nativeSoftwareManagementServiceDownloadImageClient struct {
278 grpc.ClientStream
279}
280
281func (x *nativeSoftwareManagementServiceDownloadImageClient) Recv() (*ImageStatus, error) {
282 m := new(ImageStatus)
283 if err := x.ClientStream.RecvMsg(m); err != nil {
284 return nil, err
285 }
286 return m, nil
287}
288
289func (c *nativeSoftwareManagementServiceClient) ActivateImage(ctx context.Context, in *HardwareID, opts ...grpc.CallOption) (NativeSoftwareManagementService_ActivateImageClient, error) {
290 stream, err := c.cc.NewStream(ctx, &_NativeSoftwareManagementService_serviceDesc.Streams[1], "/dmi.NativeSoftwareManagementService/ActivateImage", opts...)
291 if err != nil {
292 return nil, err
293 }
294 x := &nativeSoftwareManagementServiceActivateImageClient{stream}
295 if err := x.ClientStream.SendMsg(in); err != nil {
296 return nil, err
297 }
298 if err := x.ClientStream.CloseSend(); err != nil {
299 return nil, err
300 }
301 return x, nil
302}
303
304type NativeSoftwareManagementService_ActivateImageClient interface {
305 Recv() (*ImageStatus, error)
306 grpc.ClientStream
307}
308
309type nativeSoftwareManagementServiceActivateImageClient struct {
310 grpc.ClientStream
311}
312
313func (x *nativeSoftwareManagementServiceActivateImageClient) Recv() (*ImageStatus, error) {
314 m := new(ImageStatus)
315 if err := x.ClientStream.RecvMsg(m); err != nil {
316 return nil, err
317 }
318 return m, nil
319}
320
321func (c *nativeSoftwareManagementServiceClient) RevertToStandbyImage(ctx context.Context, in *HardwareID, opts ...grpc.CallOption) (NativeSoftwareManagementService_RevertToStandbyImageClient, error) {
322 stream, err := c.cc.NewStream(ctx, &_NativeSoftwareManagementService_serviceDesc.Streams[2], "/dmi.NativeSoftwareManagementService/RevertToStandbyImage", opts...)
323 if err != nil {
324 return nil, err
325 }
326 x := &nativeSoftwareManagementServiceRevertToStandbyImageClient{stream}
327 if err := x.ClientStream.SendMsg(in); err != nil {
328 return nil, err
329 }
330 if err := x.ClientStream.CloseSend(); err != nil {
331 return nil, err
332 }
333 return x, nil
334}
335
336type NativeSoftwareManagementService_RevertToStandbyImageClient interface {
337 Recv() (*ImageStatus, error)
338 grpc.ClientStream
339}
340
341type nativeSoftwareManagementServiceRevertToStandbyImageClient struct {
342 grpc.ClientStream
343}
344
345func (x *nativeSoftwareManagementServiceRevertToStandbyImageClient) Recv() (*ImageStatus, error) {
346 m := new(ImageStatus)
347 if err := x.ClientStream.RecvMsg(m); err != nil {
348 return nil, err
349 }
350 return m, nil
351}
352
353// NativeSoftwareManagementServiceServer is the server API for NativeSoftwareManagementService service.
354type NativeSoftwareManagementServiceServer interface {
355 // Get the software version information of the Active and Standby images
aghoshc301dcd2020-09-03 16:55:34 +0100356 GetSoftwareVersion(context.Context, *HardwareID) (*GetSoftwareVersionInformationResponse, error)
Amit Ghosh09f28362020-06-12 21:52:19 +0100357 // Downloads and installs the image in the standby partition, returns the status/progress of the Install
358 DownloadImage(*DownloadImageRequest, NativeSoftwareManagementService_DownloadImageServer) error
359 // Activates and runs the OLT with the image in the standby partition. If things are fine this image will
360 // henceforth be marked as the Active Partition. The old working image would remain on the Standby partition.
361 // Any possibly required (sub-)steps like "commit" are left to the "Device Manager"
362 ActivateImage(*HardwareID, NativeSoftwareManagementService_ActivateImageServer) error
363 // Marks the image in the Standby as Active and reboots the device, so that it boots from that image which was in the standby.
aghoshc301dcd2020-09-03 16:55:34 +0100364 // This API is to be used if operator wants to go back to the previous software
Amit Ghosh09f28362020-06-12 21:52:19 +0100365 RevertToStandbyImage(*HardwareID, NativeSoftwareManagementService_RevertToStandbyImageServer) error
366}
367
368func RegisterNativeSoftwareManagementServiceServer(s *grpc.Server, srv NativeSoftwareManagementServiceServer) {
369 s.RegisterService(&_NativeSoftwareManagementService_serviceDesc, srv)
370}
371
372func _NativeSoftwareManagementService_GetSoftwareVersion_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
373 in := new(HardwareID)
374 if err := dec(in); err != nil {
375 return nil, err
376 }
377 if interceptor == nil {
378 return srv.(NativeSoftwareManagementServiceServer).GetSoftwareVersion(ctx, in)
379 }
380 info := &grpc.UnaryServerInfo{
381 Server: srv,
382 FullMethod: "/dmi.NativeSoftwareManagementService/GetSoftwareVersion",
383 }
384 handler := func(ctx context.Context, req interface{}) (interface{}, error) {
385 return srv.(NativeSoftwareManagementServiceServer).GetSoftwareVersion(ctx, req.(*HardwareID))
386 }
387 return interceptor(ctx, in, info, handler)
388}
389
390func _NativeSoftwareManagementService_DownloadImage_Handler(srv interface{}, stream grpc.ServerStream) error {
391 m := new(DownloadImageRequest)
392 if err := stream.RecvMsg(m); err != nil {
393 return err
394 }
395 return srv.(NativeSoftwareManagementServiceServer).DownloadImage(m, &nativeSoftwareManagementServiceDownloadImageServer{stream})
396}
397
398type NativeSoftwareManagementService_DownloadImageServer interface {
399 Send(*ImageStatus) error
400 grpc.ServerStream
401}
402
403type nativeSoftwareManagementServiceDownloadImageServer struct {
404 grpc.ServerStream
405}
406
407func (x *nativeSoftwareManagementServiceDownloadImageServer) Send(m *ImageStatus) error {
408 return x.ServerStream.SendMsg(m)
409}
410
411func _NativeSoftwareManagementService_ActivateImage_Handler(srv interface{}, stream grpc.ServerStream) error {
412 m := new(HardwareID)
413 if err := stream.RecvMsg(m); err != nil {
414 return err
415 }
416 return srv.(NativeSoftwareManagementServiceServer).ActivateImage(m, &nativeSoftwareManagementServiceActivateImageServer{stream})
417}
418
419type NativeSoftwareManagementService_ActivateImageServer interface {
420 Send(*ImageStatus) error
421 grpc.ServerStream
422}
423
424type nativeSoftwareManagementServiceActivateImageServer struct {
425 grpc.ServerStream
426}
427
428func (x *nativeSoftwareManagementServiceActivateImageServer) Send(m *ImageStatus) error {
429 return x.ServerStream.SendMsg(m)
430}
431
432func _NativeSoftwareManagementService_RevertToStandbyImage_Handler(srv interface{}, stream grpc.ServerStream) error {
433 m := new(HardwareID)
434 if err := stream.RecvMsg(m); err != nil {
435 return err
436 }
437 return srv.(NativeSoftwareManagementServiceServer).RevertToStandbyImage(m, &nativeSoftwareManagementServiceRevertToStandbyImageServer{stream})
438}
439
440type NativeSoftwareManagementService_RevertToStandbyImageServer interface {
441 Send(*ImageStatus) error
442 grpc.ServerStream
443}
444
445type nativeSoftwareManagementServiceRevertToStandbyImageServer struct {
446 grpc.ServerStream
447}
448
449func (x *nativeSoftwareManagementServiceRevertToStandbyImageServer) Send(m *ImageStatus) error {
450 return x.ServerStream.SendMsg(m)
451}
452
453var _NativeSoftwareManagementService_serviceDesc = grpc.ServiceDesc{
454 ServiceName: "dmi.NativeSoftwareManagementService",
455 HandlerType: (*NativeSoftwareManagementServiceServer)(nil),
456 Methods: []grpc.MethodDesc{
457 {
458 MethodName: "GetSoftwareVersion",
459 Handler: _NativeSoftwareManagementService_GetSoftwareVersion_Handler,
460 },
461 },
462 Streams: []grpc.StreamDesc{
463 {
464 StreamName: "DownloadImage",
465 Handler: _NativeSoftwareManagementService_DownloadImage_Handler,
466 ServerStreams: true,
467 },
468 {
469 StreamName: "ActivateImage",
470 Handler: _NativeSoftwareManagementService_ActivateImage_Handler,
471 ServerStreams: true,
472 },
473 {
474 StreamName: "RevertToStandbyImage",
475 Handler: _NativeSoftwareManagementService_RevertToStandbyImage_Handler,
476 ServerStreams: true,
477 },
478 },
479 Metadata: "dmi/sw_management_service.proto",
480}