blob: 91ee6855af714fa7740562bb1d0cd8172649ac83 [file] [log] [blame]
Andy Bavier03df22b2017-08-30 14:46:02 -07001option name = "volt";
Matteo Scandolobfc31332018-03-29 09:06:52 -07002option app_label = "volt";
Andy Bavier03df22b2017-08-30 14:46:02 -07003
4message VOLTService (Service){
Matteo Scandolo43473812018-03-02 10:55:54 -08005 option verbose_name = "vOLT Service";
6 option kind = "vOLT";
Scott Baker2108e752019-01-17 07:00:32 -08007 option description = "OLT Access Service";
Scott Baker48a4f452019-05-31 17:58:21 -07008 option custom_python = "True";
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -08009
Scott Baker1e043272019-01-24 08:33:15 -080010 required string voltha_url = 1 [
11 help_text = "The Voltha API address. By default voltha.voltha.svc.cluster.local",
Scott Baker1e043272019-01-24 08:33:15 -080012 default = "voltha.voltha.svc.cluster.local",
Scott Bakera108b9c2019-04-09 14:13:44 -070013 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080014 required int32 voltha_port = 2 [
15 help_text = "The Voltha API port. By default 8882",
Scott Baker1e043272019-01-24 08:33:15 -080016 default = 8882];
17 required string voltha_user = 3 [
18 help_text = "The Voltha username. By default voltha",
Scott Baker1e043272019-01-24 08:33:15 -080019 default = "voltha",
Scott Bakera108b9c2019-04-09 14:13:44 -070020 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080021 required string voltha_pass = 4 [
22 help_text = "The Voltha password. By default admin",
Scott Baker1e043272019-01-24 08:33:15 -080023 default = "admin",
Scott Bakera108b9c2019-04-09 14:13:44 -070024 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080025 required string onos_voltha_url = 5 [
26 help_text = "The ONOS Voltha address. By default onos-voltha-ui.voltha.svc.cluster.local",
Scott Baker1e043272019-01-24 08:33:15 -080027 default = "onos-voltha-ui.voltha.svc.cluster.local",
Scott Bakera108b9c2019-04-09 14:13:44 -070028 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080029 required int32 onos_voltha_port = 6 [
30 help_text = "The Voltha API port. By default 8181",
Scott Baker1e043272019-01-24 08:33:15 -080031 default = 8181];
32 required string onos_voltha_user = 7 [
33 help_text = "The ONOS Voltha username. By default sdn",
Scott Bakera108b9c2019-04-09 14:13:44 -070034 max_length = 256,
Scott Baker1e043272019-01-24 08:33:15 -080035 default = "onos"];
36 required string onos_voltha_pass = 8 [
37 help_text = "The ONOS Voltha password. By default rocks",
Scott Bakera108b9c2019-04-09 14:13:44 -070038 max_length = 256,
Scott Baker1e043272019-01-24 08:33:15 -080039 default = "rocks"];
Andy Bavier03df22b2017-08-30 14:46:02 -070040}
41
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -080042message OLTDevice (XOSBase){
43 option verbose_name = "OLT Device";
44 option description="Represents a physical OLT device";
Scott Baker48a4f452019-05-31 17:58:21 -070045 option custom_python = "True";
Andy Bavier03df22b2017-08-30 14:46:02 -070046
Scott Baker1e043272019-01-24 08:33:15 -080047 required manytoone volt_service->VOLTService:volt_devices = 1:1001 [
48 help_text = "VOLTService that owns this OLT",
49 db_index = True];
50 optional string name = 2 [
51 help_text = "Human-readable name of device",
Scott Bakera108b9c2019-04-09 14:13:44 -070052 max_length = 256,
Scott Baker1e043272019-01-24 08:33:15 -080053 unique = True];
54 required string device_type = 3 [
55 help_text = "Phyiscal Device Type",
Scott Baker1e043272019-01-24 08:33:15 -080056 default = "openolt",
Scott Bakera108b9c2019-04-09 14:13:44 -070057 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080058 optional string host = 4 [
59 help_text = "IP Address of physical OLT Device",
Scott Bakera108b9c2019-04-09 14:13:44 -070060 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080061 optional int32 port = 5 [
62 help_text = "Port Number of physical OLT Device",
Scott Baker1e043272019-01-24 08:33:15 -080063 unique_with = "host"];
64 optional string mac_address = 6 [
Scott Bakera108b9c2019-04-09 14:13:44 -070065 help_text = "MAC address of physical OLT Device",
66 max_length = 17];
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -080067
Scott Baker1e043272019-01-24 08:33:15 -080068 optional string serial_number = 9 [
Scott Bakera108b9c2019-04-09 14:13:44 -070069 help_text = "Serial Number",
70 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080071 optional string device_id = 10 [
72 help_text = "Voltha Device ID",
Scott Bakera108b9c2019-04-09 14:13:44 -070073 feedback_state = True,
74 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080075 optional string admin_state = 11 [
76 help_text = "admin state, whether OLT should be enabled",
77 choices = "(('DISABLED', 'DISABLED'), ('ENABLED', 'ENABLED'))",
Scott Bakera108b9c2019-04-09 14:13:44 -070078 default = "ENABLED",
79 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -080080 optional string oper_status = 12 [
81 help_text = "operational status, whether OLT is active",
Scott Bakera108b9c2019-04-09 14:13:44 -070082 feedback_state = True,
83 max_length = 256];
Scott Baker12687732019-03-19 15:40:57 -070084 optional string link_status = 21 [
85 help_text = "connectivity status, whether OLT has connectivity to agg switch",
86 choices = "(('up', 'up'), ('down', 'down'))",
Scott Bakera108b9c2019-04-09 14:13:44 -070087 feedback_state = True,
88 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -080089 optional string of_id = 13 [
90 help_text = "Logical device openflow id",
Scott Bakera108b9c2019-04-09 14:13:44 -070091 feedback_state = True,
92 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080093 optional string dp_id = 14 [
Scott Bakera108b9c2019-04-09 14:13:44 -070094 help_text = "Logical device datapath id",
95 max_length = 256];
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -080096
Scott Baker1e043272019-01-24 08:33:15 -080097 required string uplink = 15 [
Scott Bakera108b9c2019-04-09 14:13:44 -070098 help_text = "uplink port, exposed via sadis",
99 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800100 required string driver = 16 [
101 help_text = "DEPRECATED",
Scott Bakera108b9c2019-04-09 14:13:44 -0700102 default = "voltha",
103 max_length = 32]; // Used to be sent to ONOS, now unused.
Matteo Scandolod3c768d2018-04-11 13:38:49 -0700104
Scott Baker1e043272019-01-24 08:33:15 -0800105 optional string switch_datapath_id = 17 [
Scott Bakera108b9c2019-04-09 14:13:44 -0700106 help_text = "Fabric switch to which the OLT is connected",
107 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800108 optional string switch_port = 18 [
Scott Bakera108b9c2019-04-09 14:13:44 -0700109 help_text = "Fabric port to which the OLT is connected",
110 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800111 optional string outer_tpid = 19 [
Scott Bakera108b9c2019-04-09 14:13:44 -0700112 help_text = "Outer VLAN id field EtherType",
113 max_length = 256];
Matteo Scandolo610c11d2018-08-31 07:33:43 -0700114
Scott Baker1e043272019-01-24 08:33:15 -0800115 optional string nas_id = 20 [
Scott Bakera108b9c2019-04-09 14:13:44 -0700116 help_text = "Authentication ID (propagated to the free-radius server via sadis)",
117 max_length = 256];
Andy Bavier03df22b2017-08-30 14:46:02 -0700118}
119
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700120message PortBase (XOSBase){
121 option gui_hidden = True;
Scott Baker1e043272019-01-24 08:33:15 -0800122 option description = "Base class for Port objects";
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700123
Scott Baker1e043272019-01-24 08:33:15 -0800124 required string name = 1 [
125 help_text = "Human-readable name of port",
Scott Bakera108b9c2019-04-09 14:13:44 -0700126 db_index = True,
127 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800128 required int32 port_no = 3 [
Scott Baker3f4816f2019-03-12 15:06:01 -0700129 help_text = "Port Number"];
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700130
Scott Baker1e043272019-01-24 08:33:15 -0800131 optional string admin_state = 4 [
132 help_text = "admin state, whether port should be enabled",
Scott Bakera108b9c2019-04-09 14:13:44 -0700133 // TODO: Should specify "choices"
134 feedback_state = True,
135 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -0800136 optional string oper_status = 5 [
137 help_text = "operational status, whether port is active",
Scott Bakera108b9c2019-04-09 14:13:44 -0700138 // TODO: Should specify "choices"
139 feedback_state = True,
140 max_length = 32];
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700141}
142
143message PONPort (PortBase){
Matteo Scandolo80912942018-07-25 20:51:30 -0700144 option verbose_name = "PON Port";
Scott Baker1e043272019-01-24 08:33:15 -0800145 option description = "PON Port";
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -0800146
Scott Baker1e043272019-01-24 08:33:15 -0800147 required manytoone olt_device->OLTDevice:pon_ports = 1:1001 [
148 help_text = "OLTDevice that owns this PONPort",
149 db_index = True];
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700150}
151
152message NNIPort (PortBase) {
153 option verbose_name = "NNI Port";
Scott Baker1e043272019-01-24 08:33:15 -0800154 option description = "NNI Port";
155
156 required manytoone olt_device->OLTDevice:nni_ports = 1:1002 [
157 help_text = "OLTDevice that owns this NNIPort",
158 db_index = True];
Andy Bavier03df22b2017-08-30 14:46:02 -0700159}
Matteo Scandoloe2cb8a42018-05-18 16:30:06 -0700160
161message ONUDevice (XOSBase){
162 option verbose_name = "ONU Device";
163 option description = "Represents a physical ONU device";
Scott Baker48a4f452019-05-31 17:58:21 -0700164 option custom_python = "True";
Matteo Scandoloe2cb8a42018-05-18 16:30:06 -0700165
Scott Baker1e043272019-01-24 08:33:15 -0800166 required manytoone pon_port->PONPort:onu_devices = 1:1001 [
167 help_text = "PONPort that connects this ONUDevice to an OLTDevice",
168 db_index = True];
169 required string serial_number = 2 [
170 help_text = "Serial number of ONU Device",
Scott Bakera108b9c2019-04-09 14:13:44 -0700171 max_length = 256,
Scott Baker1e043272019-01-24 08:33:15 -0800172 tosca_key=True,
173 unique = True];
174 required string vendor = 3 [
175 help_text = "Vendor of ONU Device",
Scott Bakera108b9c2019-04-09 14:13:44 -0700176 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800177 required string device_type = 4 [
178 help_text = "Device Type",
Scott Baker1e043272019-01-24 08:33:15 -0800179 default = "asfvolt16_olt",
Scott Bakera108b9c2019-04-09 14:13:44 -0700180 max_length = 256];
Matteo Scandoloe2cb8a42018-05-18 16:30:06 -0700181
Scott Baker1e043272019-01-24 08:33:15 -0800182 optional string device_id = 5 [
183 help_text = "Voltha Device ID",
Scott Baker1e043272019-01-24 08:33:15 -0800184 feedback_state = True,
Scott Bakera108b9c2019-04-09 14:13:44 -0700185 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800186 optional string admin_state = 6 [
187 help_text = "admin state, whether port should be enabled",
Andy Baviercd940192019-05-15 12:59:35 -0700188 choices = "(('DISABLED', 'DISABLED'), ('ENABLED', 'ENABLED'), ('ADMIN_DISABLED', 'ADMIN_DISABLED'))",
Scott Bakera108b9c2019-04-09 14:13:44 -0700189 default = "ENABLED",
190 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -0800191 optional string oper_status = 7 [
192 help_text = "oper_status",
Scott Bakera108b9c2019-04-09 14:13:44 -0700193 // TODO: Should add "choices"
194 feedback_state = True,
195 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -0800196 optional string connect_status = 8 [
197 help_text = "operational status, whether port is active",
Scott Bakera108b9c2019-04-09 14:13:44 -0700198 feedback_state = True,
199 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -0800200 optional string reason = 9 [
201 help_text = "ONU device configuration state machine status message",
Scott Bakera108b9c2019-04-09 14:13:44 -0700202 feedback_state = True,
203 text = True];
Matteo Scandolo2360fd92018-05-29 17:27:51 -0700204}
205
Matteo Scandolo915c7b82019-05-09 16:26:12 -0700206message ANIPort (PortBase) {
Matteo Scandolo80912942018-07-25 20:51:30 -0700207 option verbose_name = "ANI Port";
Scott Baker2108e752019-01-17 07:00:32 -0800208 option description="Access Node Interface Port";
Matteo Scandolo915c7b82019-05-09 16:26:12 -0700209 required manytoone onu_device->ONUDevice:ani_ports = 1:1001 [
210 help_text = "ONUDevice that owns this ANIPort",
Scott Baker1e043272019-01-24 08:33:15 -0800211 db_index = True];
Matteo Scandolod8ed60e2018-06-18 17:00:57 -0700212}
213
214message UNIPort (PortBase) {
215 option verbose_name = "UNI Port";
Scott Baker2108e752019-01-17 07:00:32 -0800216 option description = "User Network Interface Port";
Scott Baker1e043272019-01-24 08:33:15 -0800217 required manytoone onu_device->ONUDevice:uni_ports = 1:1002 [
218 help_text = "ONUDevice that owns this UNIPort",
219 db_index = True];
Matteo Scandolod8ed60e2018-06-18 17:00:57 -0700220}
221
Matteo Scandolo2360fd92018-05-29 17:27:51 -0700222message VOLTServiceInstance (ServiceInstance){
223 option kind = "vOLT";
224 option owner_class_name = "VOLTService";
225 option verbose_name = "vOLT Service Instance";
Scott Baker2108e752019-01-17 07:00:32 -0800226 option description = "Represents subscriber tenancy in the VOLT Service";
Matteo Scandolo2360fd92018-05-29 17:27:51 -0700227
Scott Baker1e043272019-01-24 08:33:15 -0800228 optional string description = 1 [
229 help_text = "Human-readable description",
Scott Bakera108b9c2019-04-09 14:13:44 -0700230 text = True];
Scott Baker1e043272019-01-24 08:33:15 -0800231 optional manytoone onu_device->ONUDevice:volt_service_instances = 2:1003 [
232 help_text = "ONUDevice that belongs to this Subscriber chain",
233 db_index = True];
Scott Baker6ff7a4a2018-10-01 12:19:49 -0700234}
Hardik Windlassda0d6c42019-05-13 16:00:01 +0000235
236message TechnologyProfile (XOSBase) {
237 option verbose_name = "Technology Profile";
238 option description = "The Technology Profile that is utilized by VOLTHA";
Scott Baker48a4f452019-05-31 17:58:21 -0700239 option custom_python = "True";
Hardik Windlassda0d6c42019-05-13 16:00:01 +0000240
241 required string technology = 1 [
242 help_text = "The technology being utilized by the adaptor",
243 db_index = True,
244 max_length = 16];
245 required int32 profile_id = 2 [
246 help_text = "The numeric id of the profile",
247 db_index = True,
248 min_value = 64,
249 max_value = 255];
250 required string profile_value = 3 [
251 help_text = "The technology profile value in JSON format",
252 max_length = 4096];
253}