blob: 28af2bf3ab4608f94174b4fd6e9977649ef562a4 [file] [log] [blame]
David K. Bainbridge24ff0232019-04-30 13:26:19 -07001syntax = "proto3";
2
3option go_package = "github.com/opencord/voltha-protos/go/inter_container";
4
Devmalya Paulf2e13782019-07-09 07:52:15 -04005import public "voltha_protos/common.proto";
6import public "voltha_protos/voltha.proto";
David K. Bainbridge24ff0232019-04-30 13:26:19 -07007import "google/protobuf/any.proto";
8import "voltha_protos/openflow_13.proto";
9import public "voltha_protos/logical_device.proto";
10
11package voltha;
12
13message StrType {
14 string val = 1;
15}
16
17message IntType {
18 int64 val = 1;
19}
20
21message BoolType {
22 bool val = 1;
23}
24
25message Packet {
26 bytes payload = 1;
27}
28
29message ErrorCode {
30 enum codes {
31 UNSUPPORTED_REQUEST = 0;
32 INVALID_PARAMETERS = 1;
33 }
34}
35
36message Error {
37 ErrorCode code = 1;
38 string reason = 2;
39}
40
41enum MessageType {
42 REQUEST = 0;
43 RESPONSE = 1;
44 DEVICE_DISCOVERED=2;
45}
46
47message Header {
48 string id = 1;
49 MessageType type = 2;
50 string from_topic = 3;
51 string to_topic = 4;
52 string key_topic = 5;
53 int64 timestamp = 6;
54}
55
56message Argument {
57 string key = 1;
58 google.protobuf.Any value = 2;
59}
60
61message InterContainerMessage {
62 Header header = 1;
63 google.protobuf.Any body = 2;
64}
65
66message InterContainerRequestBody {
67 string rpc = 2;
68 repeated Argument args = 3;
69 bool response_required = 4;
70 string reply_to_topic = 5;
71}
72
73message InterContainerResponseBody {
74 bool success = 1;
75 google.protobuf.Any result = 3;
76}
77
78message SwitchCapability {
79 openflow_13.ofp_desc desc = 1;
80 openflow_13.ofp_switch_features switch_features = 2;
81}
82
83message PortCapability {
84 LogicalPort port = 1;
85}
86
87message DeviceDiscovered {
88 string id = 1;
89 string parent_id = 2;
90 string device_type = 3;
91 string publisher = 4;
92}
93
94message InterAdapterMessageType {
95 enum Types {
96 FLOW_REQUEST = 0;
97 FLOW_RESPONSE = 1;
98 OMCI_REQUEST = 2;
99 OMCI_RESPONSE = 3;
100 METRICS_REQUEST = 4;
101 METRICS_RESPONSE = 5;
102 ONU_IND_REQUEST = 6;
103 ONU_IND_RESPONSE = 7;
104 TECH_PROFILE_DOWNLOAD_REQUEST = 8;
105 }
106}
107
108message InterAdapterHeader {
109 string id = 1;
110 InterAdapterMessageType.Types type = 2;
111 string from_topic = 3;
112 string to_topic = 4;
113 string to_device_id = 5;
114 string proxy_device_id = 6;
115 int64 timestamp = 7;
116}
117
118message InterAdapterOmciMessage {
119 bytes message = 1; // OMCI_REQUEST or OMCI_RESPONSE
Devmalya Paulf2e13782019-07-09 07:52:15 -0400120 common.ConnectStatus.ConnectStatus connect_status = 2;
121 voltha.Device.ProxyAddress proxy_address = 3;
David K. Bainbridge24ff0232019-04-30 13:26:19 -0700122}
123
124message InterAdapterTechProfileDownloadMessage {
125 uint32 uni_id = 1;
126 string path = 2;
127}
128
129message InterAdapterResponseBody {
130 bool status = 1;
131 oneof payload {
132 google.protobuf.Any body = 2;
133 InterAdapterOmciMessage omci = 3; // OMCI_REQUEST or OMCI_RESPONSE
134 }
135}
136
137message InterAdapterMessage {
138 InterAdapterHeader header = 1;
139 google.protobuf.Any body = 2;
140}