blob: 84613016c6fa35045461df16804d9b018698026b [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];
Andy Bavier03df22b2017-08-30 14:46:02 -070025}
26
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -080027message OLTDevice (XOSBase){
28 option verbose_name = "OLT Device";
29 option description="Represents a physical OLT device";
Scott Baker48a4f452019-05-31 17:58:21 -070030 option custom_python = "True";
vigneshethiraj8b163672019-06-04 18:55:19 +053031 option sync_implemented = "True";
Andy Bavier03df22b2017-08-30 14:46:02 -070032
Scott Baker1e043272019-01-24 08:33:15 -080033 required manytoone volt_service->VOLTService:volt_devices = 1:1001 [
34 help_text = "VOLTService that owns this OLT",
35 db_index = True];
36 optional string name = 2 [
37 help_text = "Human-readable name of device",
Scott Bakera108b9c2019-04-09 14:13:44 -070038 max_length = 256,
Scott Baker1e043272019-01-24 08:33:15 -080039 unique = True];
40 required string device_type = 3 [
41 help_text = "Phyiscal Device Type",
Scott Baker1e043272019-01-24 08:33:15 -080042 default = "openolt",
Scott Bakera108b9c2019-04-09 14:13:44 -070043 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080044 optional string host = 4 [
45 help_text = "IP Address of physical OLT Device",
Scott Bakera108b9c2019-04-09 14:13:44 -070046 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080047 optional int32 port = 5 [
48 help_text = "Port Number of physical OLT Device",
Scott Baker1e043272019-01-24 08:33:15 -080049 unique_with = "host"];
50 optional string mac_address = 6 [
Scott Bakera108b9c2019-04-09 14:13:44 -070051 help_text = "MAC address of physical OLT Device",
52 max_length = 17];
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -080053
Scott Baker1e043272019-01-24 08:33:15 -080054 optional string serial_number = 9 [
Scott Bakera108b9c2019-04-09 14:13:44 -070055 help_text = "Serial Number",
56 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080057 optional string device_id = 10 [
58 help_text = "Voltha Device ID",
Scott Bakera108b9c2019-04-09 14:13:44 -070059 feedback_state = True,
60 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080061 optional string admin_state = 11 [
62 help_text = "admin state, whether OLT should be enabled",
63 choices = "(('DISABLED', 'DISABLED'), ('ENABLED', 'ENABLED'))",
Scott Bakera108b9c2019-04-09 14:13:44 -070064 default = "ENABLED",
65 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -080066 optional string oper_status = 12 [
67 help_text = "operational status, whether OLT is active",
Scott Bakera108b9c2019-04-09 14:13:44 -070068 feedback_state = True,
69 max_length = 256];
Scott Baker12687732019-03-19 15:40:57 -070070 optional string link_status = 21 [
71 help_text = "connectivity status, whether OLT has connectivity to agg switch",
72 choices = "(('up', 'up'), ('down', 'down'))",
Scott Bakera108b9c2019-04-09 14:13:44 -070073 feedback_state = True,
74 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -080075 optional string of_id = 13 [
76 help_text = "Logical device openflow id",
Scott Bakera108b9c2019-04-09 14:13:44 -070077 feedback_state = True,
78 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080079 optional string dp_id = 14 [
Scott Bakera108b9c2019-04-09 14:13:44 -070080 help_text = "Logical device datapath id",
81 max_length = 256];
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -080082
Scott Baker1e043272019-01-24 08:33:15 -080083 required string uplink = 15 [
Scott Bakera108b9c2019-04-09 14:13:44 -070084 help_text = "uplink port, exposed via sadis",
85 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080086 required string driver = 16 [
87 help_text = "DEPRECATED",
Scott Bakera108b9c2019-04-09 14:13:44 -070088 default = "voltha",
89 max_length = 32]; // Used to be sent to ONOS, now unused.
Matteo Scandolod3c768d2018-04-11 13:38:49 -070090
Scott Baker1e043272019-01-24 08:33:15 -080091 optional string switch_datapath_id = 17 [
Scott Bakera108b9c2019-04-09 14:13:44 -070092 help_text = "Fabric switch to which the OLT is connected",
93 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080094 optional string switch_port = 18 [
Scott Bakera108b9c2019-04-09 14:13:44 -070095 help_text = "Fabric port to which the OLT is connected",
96 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -080097 optional string outer_tpid = 19 [
Scott Bakera108b9c2019-04-09 14:13:44 -070098 help_text = "Outer VLAN id field EtherType",
99 max_length = 256];
Matteo Scandolo610c11d2018-08-31 07:33:43 -0700100
Scott Baker1e043272019-01-24 08:33:15 -0800101 optional string nas_id = 20 [
Scott Bakera108b9c2019-04-09 14:13:44 -0700102 help_text = "Authentication ID (propagated to the free-radius server via sadis)",
103 max_length = 256];
Matteo Scandolo1dc711d2019-06-20 17:04:46 -0700104
105 required string technology = 22 [
106 help_text = "The technology being utilized by the adapter",
107 db_index = True,
Matteo Scandolo1dc711d2019-06-20 17:04:46 -0700108 max_length = 16,
109 choices = "(('gpon', 'gpon'), ('xgspon', 'xgspon'))",
110 default = "xgspon"];
Andy Bavier03df22b2017-08-30 14:46:02 -0700111}
112
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700113message PortBase (XOSBase){
114 option gui_hidden = True;
Scott Baker1e043272019-01-24 08:33:15 -0800115 option description = "Base class for Port objects";
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700116
Scott Baker1e043272019-01-24 08:33:15 -0800117 required string name = 1 [
118 help_text = "Human-readable name of port",
Scott Bakera108b9c2019-04-09 14:13:44 -0700119 db_index = True,
120 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800121 required int32 port_no = 3 [
Scott Baker3f4816f2019-03-12 15:06:01 -0700122 help_text = "Port Number"];
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700123
Scott Baker1e043272019-01-24 08:33:15 -0800124 optional string admin_state = 4 [
125 help_text = "admin state, whether port should be enabled",
Scott Bakera108b9c2019-04-09 14:13:44 -0700126 feedback_state = True,
127 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -0800128 optional string oper_status = 5 [
129 help_text = "operational status, whether port is active",
Scott Bakera108b9c2019-04-09 14:13:44 -0700130 feedback_state = True,
131 max_length = 32];
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700132}
133
134message PONPort (PortBase){
Matteo Scandolo80912942018-07-25 20:51:30 -0700135 option verbose_name = "PON Port";
Scott Baker1e043272019-01-24 08:33:15 -0800136 option description = "PON Port";
Matteo Scandolo4a8b4d62018-03-06 17:18:46 -0800137
Scott Baker1e043272019-01-24 08:33:15 -0800138 required manytoone olt_device->OLTDevice:pon_ports = 1:1001 [
139 help_text = "OLTDevice that owns this PONPort",
140 db_index = True];
Matteo Scandolo6be6ee92018-05-24 15:07:51 -0700141}
142
143message NNIPort (PortBase) {
144 option verbose_name = "NNI Port";
Scott Baker1e043272019-01-24 08:33:15 -0800145 option description = "NNI Port";
146
147 required manytoone olt_device->OLTDevice:nni_ports = 1:1002 [
148 help_text = "OLTDevice that owns this NNIPort",
149 db_index = True];
Andy Bavier03df22b2017-08-30 14:46:02 -0700150}
Matteo Scandoloe2cb8a42018-05-18 16:30:06 -0700151
152message ONUDevice (XOSBase){
153 option verbose_name = "ONU Device";
154 option description = "Represents a physical ONU device";
Scott Baker48a4f452019-05-31 17:58:21 -0700155 option custom_python = "True";
vigneshethiraj8b163672019-06-04 18:55:19 +0530156 option sync_implemented = "True";
Matteo Scandoloe2cb8a42018-05-18 16:30:06 -0700157
Scott Baker1e043272019-01-24 08:33:15 -0800158 required manytoone pon_port->PONPort:onu_devices = 1:1001 [
159 help_text = "PONPort that connects this ONUDevice to an OLTDevice",
160 db_index = True];
161 required string serial_number = 2 [
162 help_text = "Serial number of ONU Device",
Scott Bakera108b9c2019-04-09 14:13:44 -0700163 max_length = 256,
Scott Baker1e043272019-01-24 08:33:15 -0800164 tosca_key=True,
165 unique = True];
166 required string vendor = 3 [
167 help_text = "Vendor of ONU Device",
Scott Bakera108b9c2019-04-09 14:13:44 -0700168 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800169 required string device_type = 4 [
170 help_text = "Device Type",
Scott Baker1e043272019-01-24 08:33:15 -0800171 default = "asfvolt16_olt",
Scott Bakera108b9c2019-04-09 14:13:44 -0700172 max_length = 256];
Matteo Scandoloe2cb8a42018-05-18 16:30:06 -0700173
Scott Baker1e043272019-01-24 08:33:15 -0800174 optional string device_id = 5 [
175 help_text = "Voltha Device ID",
Scott Baker1e043272019-01-24 08:33:15 -0800176 feedback_state = True,
Scott Bakera108b9c2019-04-09 14:13:44 -0700177 max_length = 256];
Scott Baker1e043272019-01-24 08:33:15 -0800178 optional string admin_state = 6 [
179 help_text = "admin state, whether port should be enabled",
Andy Baviercd940192019-05-15 12:59:35 -0700180 choices = "(('DISABLED', 'DISABLED'), ('ENABLED', 'ENABLED'), ('ADMIN_DISABLED', 'ADMIN_DISABLED'))",
Scott Bakera108b9c2019-04-09 14:13:44 -0700181 default = "ENABLED",
182 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -0800183 optional string oper_status = 7 [
184 help_text = "oper_status",
Scott Bakera108b9c2019-04-09 14:13:44 -0700185 // TODO: Should add "choices"
186 feedback_state = True,
187 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -0800188 optional string connect_status = 8 [
189 help_text = "operational status, whether port is active",
Scott Bakera108b9c2019-04-09 14:13:44 -0700190 feedback_state = True,
191 max_length = 32];
Scott Baker1e043272019-01-24 08:33:15 -0800192 optional string reason = 9 [
193 help_text = "ONU device configuration state machine status message",
Scott Bakera108b9c2019-04-09 14:13:44 -0700194 feedback_state = True,
195 text = True];
Matteo Scandolo2360fd92018-05-29 17:27:51 -0700196}
197
Matteo Scandolo915c7b82019-05-09 16:26:12 -0700198message ANIPort (PortBase) {
Matteo Scandolo80912942018-07-25 20:51:30 -0700199 option verbose_name = "ANI Port";
Scott Baker2108e752019-01-17 07:00:32 -0800200 option description="Access Node Interface Port";
Matteo Scandolo915c7b82019-05-09 16:26:12 -0700201 required manytoone onu_device->ONUDevice:ani_ports = 1:1001 [
202 help_text = "ONUDevice that owns this ANIPort",
Scott Baker1e043272019-01-24 08:33:15 -0800203 db_index = True];
Matteo Scandolod8ed60e2018-06-18 17:00:57 -0700204}
205
206message UNIPort (PortBase) {
207 option verbose_name = "UNI Port";
Scott Baker2108e752019-01-17 07:00:32 -0800208 option description = "User Network Interface Port";
Scott Baker1e043272019-01-24 08:33:15 -0800209 required manytoone onu_device->ONUDevice:uni_ports = 1:1002 [
210 help_text = "ONUDevice that owns this UNIPort",
211 db_index = True];
Matteo Scandolod8ed60e2018-06-18 17:00:57 -0700212}
213
Matteo Scandolo2360fd92018-05-29 17:27:51 -0700214message VOLTServiceInstance (ServiceInstance){
215 option kind = "vOLT";
216 option owner_class_name = "VOLTService";
217 option verbose_name = "vOLT Service Instance";
Scott Baker2108e752019-01-17 07:00:32 -0800218 option description = "Represents subscriber tenancy in the VOLT Service";
vigneshethiraj8b163672019-06-04 18:55:19 +0530219 option policy_implemented = "True";
Matteo Scandolo82026252019-06-20 12:11:45 -0700220 option sync_implemented = "True";
Matteo Scandolo2360fd92018-05-29 17:27:51 -0700221
Scott Baker1e043272019-01-24 08:33:15 -0800222 optional string description = 1 [
223 help_text = "Human-readable description",
Scott Bakera108b9c2019-04-09 14:13:44 -0700224 text = True];
Scott Baker1e043272019-01-24 08:33:15 -0800225 optional manytoone onu_device->ONUDevice:volt_service_instances = 2:1003 [
226 help_text = "ONUDevice that belongs to this Subscriber chain",
227 db_index = True];
Scott Baker6ff7a4a2018-10-01 12:19:49 -0700228}
Hardik Windlassda0d6c42019-05-13 16:00:01 +0000229
230message TechnologyProfile (XOSBase) {
231 option verbose_name = "Technology Profile";
232 option description = "The Technology Profile that is utilized by VOLTHA";
Scott Baker48a4f452019-05-31 17:58:21 -0700233 option custom_python = "True";
Hardik Windlassda0d6c42019-05-13 16:00:01 +0000234
235 required string technology = 1 [
236 help_text = "The technology being utilized by the adaptor",
237 db_index = True,
Matteo Scandolo7bba07b2019-06-11 09:34:04 -0700238 tosca_key = True,
Matteo Scandolo2b4c8472019-06-26 18:06:47 -0700239 choices = "(('gpon', 'gpon'), ('xgspon', 'xgspon'))",
Hardik Windlassda0d6c42019-05-13 16:00:01 +0000240 max_length = 16];
241 required int32 profile_id = 2 [
242 help_text = "The numeric id of the profile",
243 db_index = True,
Matteo Scandolo7bba07b2019-06-11 09:34:04 -0700244 tosca_key = True,
Hardik Windlassda0d6c42019-05-13 16:00:01 +0000245 min_value = 64,
Matteo Scandolo1dc711d2019-06-20 17:04:46 -0700246 max_value = 255,
247 unique_with = "technology"];
248
Hardik Windlassda0d6c42019-05-13 16:00:01 +0000249 required string profile_value = 3 [
250 help_text = "The technology profile value in JSON format",
251 max_length = 4096];
252}