blob: f8397aef230a341222e460b8d3149e0cb6fe6d40 [file] [log] [blame]
Zack Williams52209662019-02-07 10:15:31 -07001syntax = "proto3";
2
Serkant Uluderyacbcfaa42019-10-18 13:25:08 +03003option go_package = "github.com/opencord/voltha-protos/v3/go/inter_container";
4option 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";
11
Zack Williams52209662019-02-07 10:15:31 -070012package voltha;
13
14message StrType {
15 string val = 1;
16}
17
18message IntType {
19 int64 val = 1;
20}
21
22message BoolType {
23 bool val = 1;
24}
25
26message Packet {
27 bytes payload = 1;
28}
29
30message ErrorCode {
31 enum codes {
32 UNSUPPORTED_REQUEST = 0;
33 INVALID_PARAMETERS = 1;
Matteo Scandolo865803a2020-01-23 10:26:49 -080034 DEADLINE_EXCEEDED = 2;
Zack Williams52209662019-02-07 10:15:31 -070035 }
36}
37
38message Error {
Matteo Scandolodeed92f2020-01-21 15:49:55 -080039 ErrorCode.codes code = 1;
Zack Williams52209662019-02-07 10:15:31 -070040 string reason = 2;
41}
42
43enum MessageType {
44 REQUEST = 0;
45 RESPONSE = 1;
46 DEVICE_DISCOVERED=2;
47}
48
49message Header {
50 string id = 1;
51 MessageType type = 2;
52 string from_topic = 3;
53 string to_topic = 4;
William Kurkian6ea97f82019-03-13 15:51:55 -040054 string key_topic = 5;
55 int64 timestamp = 6;
Zack Williams52209662019-02-07 10:15:31 -070056}
57
58message Argument {
59 string key = 1;
60 google.protobuf.Any value = 2;
61}
62
63message InterContainerMessage {
64 Header header = 1;
65 google.protobuf.Any body = 2;
66}
67
68message InterContainerRequestBody {
69 string rpc = 2;
70 repeated Argument args = 3;
71 bool response_required = 4;
72 string reply_to_topic = 5;
73}
74
75message InterContainerResponseBody {
76 bool success = 1;
77 google.protobuf.Any result = 3;
78}
79
80message SwitchCapability {
81 openflow_13.ofp_desc desc = 1;
82 openflow_13.ofp_switch_features switch_features = 2;
83}
84
85message PortCapability {
86 LogicalPort port = 1;
87}
88
89message DeviceDiscovered {
90 string id = 1;
91 string parent_id = 2;
92 string device_type = 3;
93 string publisher = 4;
94}
95
96message InterAdapterMessageType {
97 enum Types {
98 FLOW_REQUEST = 0;
99 FLOW_RESPONSE = 1;
100 OMCI_REQUEST = 2;
101 OMCI_RESPONSE = 3;
102 METRICS_REQUEST = 4;
103 METRICS_RESPONSE = 5;
Matt Jeanneret909d7dc2019-03-08 17:21:09 -0500104 ONU_IND_REQUEST = 6;
105 ONU_IND_RESPONSE = 7;
Matt Jeanneret15249fa2019-04-12 20:25:31 -0400106 TECH_PROFILE_DOWNLOAD_REQUEST = 8;
Girish Gowdra475e63e2019-11-20 16:42:59 +0530107 DELETE_GEM_PORT_REQUEST = 9;
108 DELETE_TCONT_REQUEST = 10;
Zack Williams52209662019-02-07 10:15:31 -0700109 }
110}
111
112message InterAdapterHeader {
113 string id = 1;
114 InterAdapterMessageType.Types type = 2;
115 string from_topic = 3;
116 string to_topic = 4;
117 string to_device_id = 5;
118 string proxy_device_id = 6;
119 int64 timestamp = 7;
120}
121
122message InterAdapterOmciMessage {
123 bytes message = 1; // OMCI_REQUEST or OMCI_RESPONSE
Serkant Uluderyacbcfaa42019-10-18 13:25:08 +0300124 common.ConnectStatus.Types connect_status = 2;
Mahir Gunyel4b0dab22019-05-16 13:56:09 -0700125 voltha.Device.ProxyAddress proxy_address = 3;
Zack Williams52209662019-02-07 10:15:31 -0700126}
127
Matt Jeanneret15249fa2019-04-12 20:25:31 -0400128message InterAdapterTechProfileDownloadMessage {
129 uint32 uni_id = 1;
130 string path = 2;
131}
132
Girish Gowdra475e63e2019-11-20 16:42:59 +0530133message InterAdapterDeleteGemPortMessage {
134 uint32 uni_id = 1;
135 string tp_path = 2;
136 uint32 gem_port_id = 3;
137}
138
139message InterAdapterDeleteTcontMessage {
140 uint32 uni_id = 1;
141 string tp_path = 2;
142 uint32 alloc_id = 3;
143}
144
Zack Williams52209662019-02-07 10:15:31 -0700145message InterAdapterResponseBody {
146 bool status = 1;
147 oneof payload {
148 google.protobuf.Any body = 2;
149 InterAdapterOmciMessage omci = 3; // OMCI_REQUEST or OMCI_RESPONSE
150 }
151}
152
153message InterAdapterMessage {
154 InterAdapterHeader header = 1;
155 google.protobuf.Any body = 2;
156}