blob: 755b92a2d8cc8be0ac10bc6e225f4e5d61e8614c [file] [log] [blame]
Zack Williams52209662019-02-07 10:15:31 -07001syntax = "proto3";
2
Matteo Scandolob3c08ae2020-10-14 13:15:43 -07003option go_package = "github.com/opencord/voltha-protos/v4/go/inter_container";
Serkant Uluderyacbcfaa42019-10-18 13:25:08 +03004option java_package = "org.opencord.voltha";
William Kurkianad745652019-03-20 08:45:51 -04005
Mahir Gunyel4b0dab22019-05-16 13:56:09 -07006import public "voltha_protos/common.proto";
7import public "voltha_protos/voltha.proto";
Zack Williams52209662019-02-07 10:15:31 -07008import "google/protobuf/any.proto";
9import "voltha_protos/openflow_13.proto";
10import public "voltha_protos/logical_device.proto";
Scott Baker06cb92d2020-04-16 10:05:23 -070011import "google/protobuf/timestamp.proto";
Girish Gowdra9c3e1c82021-06-01 14:29:34 -070012import "voltha_protos/tech_profile.proto";
13
Zack Williams52209662019-02-07 10:15:31 -070014
Zack Williams52209662019-02-07 10:15:31 -070015package voltha;
16
17message StrType {
18 string val = 1;
19}
20
21message IntType {
22 int64 val = 1;
23}
24
25message BoolType {
26 bool val = 1;
27}
28
29message Packet {
30 bytes payload = 1;
31}
32
33message ErrorCode {
34 enum codes {
35 UNSUPPORTED_REQUEST = 0;
36 INVALID_PARAMETERS = 1;
Matteo Scandolo865803a2020-01-23 10:26:49 -080037 DEADLINE_EXCEEDED = 2;
Zack Williams52209662019-02-07 10:15:31 -070038 }
39}
40
41message Error {
Matteo Scandolodeed92f2020-01-21 15:49:55 -080042 ErrorCode.codes code = 1;
Zack Williams52209662019-02-07 10:15:31 -070043 string reason = 2;
44}
45
46enum MessageType {
47 REQUEST = 0;
48 RESPONSE = 1;
49 DEVICE_DISCOVERED=2;
50}
51
52message Header {
53 string id = 1;
54 MessageType type = 2;
55 string from_topic = 3;
56 string to_topic = 4;
William Kurkian6ea97f82019-03-13 15:51:55 -040057 string key_topic = 5;
Scott Baker06cb92d2020-04-16 10:05:23 -070058 google.protobuf.Timestamp timestamp = 6;
Zack Williams52209662019-02-07 10:15:31 -070059}
60
61message Argument {
62 string key = 1;
63 google.protobuf.Any value = 2;
64}
65
66message InterContainerMessage {
67 Header header = 1;
68 google.protobuf.Any body = 2;
69}
70
71message InterContainerRequestBody {
72 string rpc = 2;
73 repeated Argument args = 3;
74 bool response_required = 4;
75 string reply_to_topic = 5;
76}
77
78message InterContainerResponseBody {
79 bool success = 1;
80 google.protobuf.Any result = 3;
81}
82
83message SwitchCapability {
84 openflow_13.ofp_desc desc = 1;
85 openflow_13.ofp_switch_features switch_features = 2;
86}
87
Zack Williams52209662019-02-07 10:15:31 -070088message DeviceDiscovered {
89 string id = 1;
90 string parent_id = 2;
91 string device_type = 3;
92 string publisher = 4;
93}
94
95message InterAdapterMessageType {
96 enum Types {
97 FLOW_REQUEST = 0;
98 FLOW_RESPONSE = 1;
99 OMCI_REQUEST = 2;
100 OMCI_RESPONSE = 3;
101 METRICS_REQUEST = 4;
102 METRICS_RESPONSE = 5;
Matt Jeanneret909d7dc2019-03-08 17:21:09 -0500103 ONU_IND_REQUEST = 6;
104 ONU_IND_RESPONSE = 7;
Matt Jeanneret15249fa2019-04-12 20:25:31 -0400105 TECH_PROFILE_DOWNLOAD_REQUEST = 8;
Girish Gowdra475e63e2019-11-20 16:42:59 +0530106 DELETE_GEM_PORT_REQUEST = 9;
107 DELETE_TCONT_REQUEST = 10;
Zack Williams52209662019-02-07 10:15:31 -0700108 }
109}
110
111message InterAdapterHeader {
112 string id = 1;
113 InterAdapterMessageType.Types type = 2;
114 string from_topic = 3;
115 string to_topic = 4;
116 string to_device_id = 5;
117 string proxy_device_id = 6;
Scott Baker06cb92d2020-04-16 10:05:23 -0700118 google.protobuf.Timestamp timestamp = 7;
Zack Williams52209662019-02-07 10:15:31 -0700119}
120
121message InterAdapterOmciMessage {
122 bytes message = 1; // OMCI_REQUEST or OMCI_RESPONSE
Serkant Uluderyacbcfaa42019-10-18 13:25:08 +0300123 common.ConnectStatus.Types connect_status = 2;
Mahir Gunyel4b0dab22019-05-16 13:56:09 -0700124 voltha.Device.ProxyAddress proxy_address = 3;
Zack Williams52209662019-02-07 10:15:31 -0700125}
126
Girish Gowdra9c3e1c82021-06-01 14:29:34 -0700127message InterAdapterTechProfileInstanceRequestMessage {
128 string tp_instance_path = 1; // technology profile instance path
129 string parent_device_id = 2;
130 uint32 parent_pon_port = 3;
131 uint32 onu_id = 4;
132 uint32 uni_id = 5;
133}
134
Matt Jeanneret15249fa2019-04-12 20:25:31 -0400135message InterAdapterTechProfileDownloadMessage {
136 uint32 uni_id = 1;
Girish Gowdra9c3e1c82021-06-01 14:29:34 -0700137 string tp_instance_path = 2;
138 oneof tech_tp_instance {
139 tech_profile.TechProfileInstance tp_instance = 3; // relevant for GPON, XGPON and XGS-PON technologies
140 tech_profile.EponTechProfileInstance epon_tp_instance = 4; // relevant for EPON technology
141 }
Matt Jeanneret15249fa2019-04-12 20:25:31 -0400142}
143
Girish Gowdra475e63e2019-11-20 16:42:59 +0530144message InterAdapterDeleteGemPortMessage {
145 uint32 uni_id = 1;
Girish Gowdra9c3e1c82021-06-01 14:29:34 -0700146 string tp_instance_path = 2;
Girish Gowdra475e63e2019-11-20 16:42:59 +0530147 uint32 gem_port_id = 3;
148}
149
150message InterAdapterDeleteTcontMessage {
151 uint32 uni_id = 1;
Girish Gowdra9c3e1c82021-06-01 14:29:34 -0700152 string tp_instance_path = 2;
Girish Gowdra475e63e2019-11-20 16:42:59 +0530153 uint32 alloc_id = 3;
154}
155
Zack Williams52209662019-02-07 10:15:31 -0700156message InterAdapterResponseBody {
157 bool status = 1;
158 oneof payload {
159 google.protobuf.Any body = 2;
160 InterAdapterOmciMessage omci = 3; // OMCI_REQUEST or OMCI_RESPONSE
161 }
162}
163
164message InterAdapterMessage {
165 InterAdapterHeader header = 1;
166 google.protobuf.Any body = 2;
167}