Zack Williams | 5220966 | 2019-02-07 10:15:31 -0700 | [diff] [blame] | 1 | syntax = "proto3"; |
| 2 | |
Serkant Uluderya | cbcfaa4 | 2019-10-18 13:25:08 +0300 | [diff] [blame] | 3 | option go_package = "github.com/opencord/voltha-protos/v3/go/inter_container"; |
| 4 | option java_package = "org.opencord.voltha"; |
William Kurkian | ad74565 | 2019-03-20 08:45:51 -0400 | [diff] [blame] | 5 | |
Mahir Gunyel | 4b0dab2 | 2019-05-16 13:56:09 -0700 | [diff] [blame] | 6 | import public "voltha_protos/common.proto"; |
| 7 | import public "voltha_protos/voltha.proto"; |
Zack Williams | 5220966 | 2019-02-07 10:15:31 -0700 | [diff] [blame] | 8 | import "google/protobuf/any.proto"; |
| 9 | import "voltha_protos/openflow_13.proto"; |
| 10 | import public "voltha_protos/logical_device.proto"; |
| 11 | |
Zack Williams | 5220966 | 2019-02-07 10:15:31 -0700 | [diff] [blame] | 12 | package voltha; |
| 13 | |
| 14 | message StrType { |
| 15 | string val = 1; |
| 16 | } |
| 17 | |
| 18 | message IntType { |
| 19 | int64 val = 1; |
| 20 | } |
| 21 | |
| 22 | message BoolType { |
| 23 | bool val = 1; |
| 24 | } |
| 25 | |
| 26 | message Packet { |
| 27 | bytes payload = 1; |
| 28 | } |
| 29 | |
| 30 | message ErrorCode { |
| 31 | enum codes { |
| 32 | UNSUPPORTED_REQUEST = 0; |
| 33 | INVALID_PARAMETERS = 1; |
| 34 | } |
| 35 | } |
| 36 | |
| 37 | message Error { |
| 38 | ErrorCode code = 1; |
| 39 | string reason = 2; |
| 40 | } |
| 41 | |
| 42 | enum MessageType { |
| 43 | REQUEST = 0; |
| 44 | RESPONSE = 1; |
| 45 | DEVICE_DISCOVERED=2; |
| 46 | } |
| 47 | |
| 48 | message Header { |
| 49 | string id = 1; |
| 50 | MessageType type = 2; |
| 51 | string from_topic = 3; |
| 52 | string to_topic = 4; |
William Kurkian | 6ea97f8 | 2019-03-13 15:51:55 -0400 | [diff] [blame] | 53 | string key_topic = 5; |
| 54 | int64 timestamp = 6; |
Zack Williams | 5220966 | 2019-02-07 10:15:31 -0700 | [diff] [blame] | 55 | } |
| 56 | |
| 57 | message Argument { |
| 58 | string key = 1; |
| 59 | google.protobuf.Any value = 2; |
| 60 | } |
| 61 | |
| 62 | message InterContainerMessage { |
| 63 | Header header = 1; |
| 64 | google.protobuf.Any body = 2; |
| 65 | } |
| 66 | |
| 67 | message InterContainerRequestBody { |
| 68 | string rpc = 2; |
| 69 | repeated Argument args = 3; |
| 70 | bool response_required = 4; |
| 71 | string reply_to_topic = 5; |
| 72 | } |
| 73 | |
| 74 | message InterContainerResponseBody { |
| 75 | bool success = 1; |
| 76 | google.protobuf.Any result = 3; |
| 77 | } |
| 78 | |
| 79 | message SwitchCapability { |
| 80 | openflow_13.ofp_desc desc = 1; |
| 81 | openflow_13.ofp_switch_features switch_features = 2; |
| 82 | } |
| 83 | |
| 84 | message PortCapability { |
| 85 | LogicalPort port = 1; |
| 86 | } |
| 87 | |
| 88 | message DeviceDiscovered { |
| 89 | string id = 1; |
| 90 | string parent_id = 2; |
| 91 | string device_type = 3; |
| 92 | string publisher = 4; |
| 93 | } |
| 94 | |
| 95 | message 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 Jeanneret | 909d7dc | 2019-03-08 17:21:09 -0500 | [diff] [blame] | 103 | ONU_IND_REQUEST = 6; |
| 104 | ONU_IND_RESPONSE = 7; |
Matt Jeanneret | 15249fa | 2019-04-12 20:25:31 -0400 | [diff] [blame] | 105 | TECH_PROFILE_DOWNLOAD_REQUEST = 8; |
Girish Gowdra | 475e63e | 2019-11-20 16:42:59 +0530 | [diff] [blame] | 106 | DELETE_GEM_PORT_REQUEST = 9; |
| 107 | DELETE_TCONT_REQUEST = 10; |
Zack Williams | 5220966 | 2019-02-07 10:15:31 -0700 | [diff] [blame] | 108 | } |
| 109 | } |
| 110 | |
| 111 | message 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; |
| 118 | int64 timestamp = 7; |
| 119 | } |
| 120 | |
| 121 | message InterAdapterOmciMessage { |
| 122 | bytes message = 1; // OMCI_REQUEST or OMCI_RESPONSE |
Serkant Uluderya | cbcfaa4 | 2019-10-18 13:25:08 +0300 | [diff] [blame] | 123 | common.ConnectStatus.Types connect_status = 2; |
Mahir Gunyel | 4b0dab2 | 2019-05-16 13:56:09 -0700 | [diff] [blame] | 124 | voltha.Device.ProxyAddress proxy_address = 3; |
Zack Williams | 5220966 | 2019-02-07 10:15:31 -0700 | [diff] [blame] | 125 | } |
| 126 | |
Matt Jeanneret | 15249fa | 2019-04-12 20:25:31 -0400 | [diff] [blame] | 127 | message InterAdapterTechProfileDownloadMessage { |
| 128 | uint32 uni_id = 1; |
| 129 | string path = 2; |
| 130 | } |
| 131 | |
Girish Gowdra | 475e63e | 2019-11-20 16:42:59 +0530 | [diff] [blame] | 132 | message InterAdapterDeleteGemPortMessage { |
| 133 | uint32 uni_id = 1; |
| 134 | string tp_path = 2; |
| 135 | uint32 gem_port_id = 3; |
| 136 | } |
| 137 | |
| 138 | message InterAdapterDeleteTcontMessage { |
| 139 | uint32 uni_id = 1; |
| 140 | string tp_path = 2; |
| 141 | uint32 alloc_id = 3; |
| 142 | } |
| 143 | |
Zack Williams | 5220966 | 2019-02-07 10:15:31 -0700 | [diff] [blame] | 144 | message InterAdapterResponseBody { |
| 145 | bool status = 1; |
| 146 | oneof payload { |
| 147 | google.protobuf.Any body = 2; |
| 148 | InterAdapterOmciMessage omci = 3; // OMCI_REQUEST or OMCI_RESPONSE |
| 149 | } |
| 150 | } |
| 151 | |
| 152 | message InterAdapterMessage { |
| 153 | InterAdapterHeader header = 1; |
| 154 | google.protobuf.Any body = 2; |
| 155 | } |