blob: 08578a44111a0b48b2833cf6022f8f77f5d96df0 [file] [log] [blame]
khenaidoo4c6543e2021-10-19 17:25:58 -04001syntax = "proto3";
2
3option go_package = "github.com/opencord/voltha-protos/v5/go/adapter_service";
4option java_package = "org.opencord.voltha.adapter_service";
5option java_outer_classname = "VolthaAdapterService";
6
7package adapter_service;
8
9import "google/protobuf/empty.proto";
10import "voltha_protos/common.proto";
11import "voltha_protos/core_adapter.proto";
12import "voltha_protos/device.proto";
13import "voltha_protos/extensions.proto";
14import "voltha_protos/health.proto";
15import "voltha_protos/voltha.proto";
16import "voltha_protos/omci_test.proto";
17import "voltha_protos/events.proto";
18
19// AdapterService is a gRPC service to serve requests from Voltha RW_Core.
20service AdapterService {
21 // GetHealthStatus is used by an AdapterService client to verify connectivity
22 // to the gRPC server hosting the AdapterService service
khenaidoo257f3192021-12-15 16:46:37 -050023 rpc GetHealthStatus(stream common.Connection) returns (stream health.HealthStatus);
khenaidoo4c6543e2021-10-19 17:25:58 -040024
25 // Device
26 rpc AdoptDevice(device.Device) returns(google.protobuf.Empty);
27 rpc ReconcileDevice(device.Device) returns(google.protobuf.Empty);
28 rpc DeleteDevice(device.Device) returns(google.protobuf.Empty);
29 rpc DisableDevice(device.Device) returns(google.protobuf.Empty);
30 rpc ReEnableDevice(device.Device) returns(google.protobuf.Empty);
31 rpc RebootDevice(device.Device) returns(google.protobuf.Empty);
32 rpc SelfTestDevice(device.Device) returns(google.protobuf.Empty);
33 rpc GetOfpDeviceInfo(device.Device) returns(core_adapter.SwitchCapability);
34 rpc ChildDeviceLost(device.Device) returns(google.protobuf.Empty);
35
36 // Ports
37 rpc EnablePort(device.Port) returns(google.protobuf.Empty);
38 rpc DisablePort(device.Port) returns(google.protobuf.Empty);
39
40 // Flows
41 rpc UpdateFlowsBulk(core_adapter.BulkFlows) returns(google.protobuf.Empty);
42 rpc UpdateFlowsIncrementally(core_adapter.IncrementalFlows) returns(google.protobuf.Empty);
43
44 //Packets
45 rpc SendPacketOut(core_adapter.PacketOut) returns(google.protobuf.Empty);
46
47 // PM
48 rpc UpdatePmConfig(core_adapter.PmConfigsInfo) returns(google.protobuf.Empty);
49
50 // Image
51 rpc DownloadOnuImage(device.DeviceImageDownloadRequest) returns (device.DeviceImageResponse);
52 rpc GetOnuImageStatus(device.DeviceImageRequest) returns (device.DeviceImageResponse);
53 rpc AbortOnuImageUpgrade(device.DeviceImageRequest) returns (device.DeviceImageResponse);
54 rpc GetOnuImages(common.ID) returns (device.OnuImages);
55 rpc ActivateOnuImage(device.DeviceImageRequest) returns (device.DeviceImageResponse);
56 rpc CommitOnuImage(device.DeviceImageRequest) returns (device.DeviceImageResponse);
57
58 // Deprecated Image APIs
59 rpc DownloadImage(core_adapter.ImageDownloadMessage) returns (device.ImageDownload) {
60 option deprecated = true;
61 };
62 rpc GetImageDownloadStatus(core_adapter.ImageDownloadMessage) returns (device.ImageDownload) {
63 option deprecated = true;
64 };
65 rpc CancelImageDownload(core_adapter.ImageDownloadMessage) returns (device.ImageDownload) {
66 option deprecated = true;
67 };
68 rpc ActivateImageUpdate(core_adapter.ImageDownloadMessage) returns (device.ImageDownload) {
69 option deprecated = true;
70 };
71 rpc RevertImageUpdate(core_adapter.ImageDownloadMessage) returns (device.ImageDownload) {
72 option deprecated = true;
73 };
74
75 // Tests
76 rpc StartOmciTest(core_adapter.OMCITest) returns(omci.TestResponse);
77 rpc SimulateAlarm(core_adapter.SimulateAlarmMessage) returns (common.OperationResp);
78
79 // Events
80 rpc SuppressEvent(event.EventFilter) returns(google.protobuf.Empty);
81 rpc UnSuppressEvent(event.EventFilter) returns(google.protobuf.Empty);
82
83 // Get/Set
84 rpc GetExtValue(core_adapter.GetExtValueMessage) returns (extension.ReturnValues);
85 rpc SetExtValue(core_adapter.SetExtValueMessage) returns (google.protobuf.Empty);
86 rpc GetSingleValue(extension.SingleGetValueRequest) returns (extension.SingleGetValueResponse);
87 rpc SetSingleValue(extension.SingleSetValueRequest) returns (extension.SingleSetValueResponse);
88}