1 module org-openroadm-resource-types {
2 namespace "http://org/openroadm/resource/types";
3 prefix org-openroadm-resource-types;
5 import org-openroadm-common-node-types {
6 prefix org-openroadm-common-node-types;
7 revision-date 2018-11-30;
15 "YANG definitions of common resource types.
17 Copyright of the Members of the Open ROADM MSA Agreement dated (c) 2016,
18 All other rights reserved.
20 Redistribution and use in source and binary forms, with or without modification,
21 are permitted provided that the following conditions are met:
23 * Redistributions of source code must retain the above copyright notice, this
24 list of conditions and the following disclaimer.
25 * Redistributions in binary form must reproduce the above copyright notice,
26 this list of conditions and the following disclaimer in the documentation and/or
27 other materials provided with the distribution.
28 * Neither the Members of the Open ROADM MSA Agreement nor the names of its
29 contributors may be used to endorse or promote products derived from this software
30 without specific prior written permission.
32 THIS SOFTWARE IS PROVIDED BY THE MEMBERS OF THE OPEN ROADM MSA AGREEMENT ''AS IS''
33 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
34 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
35 IN NO EVENT THE MEMBERS OF THE OPEN ROADM MSA AGREEMENT BE LIABLE FOR ANY DIRECT,
36 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
37 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
38 OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
39 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
40 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
41 POSSIBILITY OF SUCH DAMAGE";
72 typedef resource-type-enum {
77 "Resource of type not found in list.";
82 "device - ROAMD, Xponder, etc";
89 enum "shared-risk-group" {
97 "connection - this is used by roadm-connection and odu-connection
98 since they are mutually exclusive in the model";
100 enum "connection-map" {
110 enum "circuit-pack" {
115 enum "internal-link" {
120 enum "physical-link" {
145 enum "line-amplifier" {
155 enum "versioned-service" {
160 enum "temp-service" {
168 typedef resource-notification-type {
170 enum "resourceCreation" {
173 "A new instance of a resource has been created.";
175 enum "resourceModification" {
178 "An existing instance of a resource has been modified. This shall be triggered by changes in configuration, state, status etc.
179 It shall not be triggered by changes in performance measurements, power and temperature readings or any other data that is highly volatile. ";
181 enum "resourceDeletion" {
184 "An existing instance of a resource has been removed.";
188 "Type of notification about a resource";
191 grouping resource-type {
193 type resource-type-enum;
204 "Device identifier. Unique within the Controller.";
206 type org-openroadm-common-node-types:node-id-type;
208 "Node Id is a globally unique identifier for a device.
209 Same as leafref value in model, if applicable.";
213 grouping circuit-pack-name {
214 leaf circuit-pack-name {
218 "Circuit-Pack identifier. Unique within the context of a device.
219 Same as leafref value in model, if applicable.";
224 uses circuit-pack-name;
228 "Port identifier. Unique within the context of a circuit-pack.
229 Same as leafref value in model, if applicable.";
233 grouping physical-link-name {
234 leaf physical-link-name {
238 "Physical Link identifier. Unique within the context of a device.
239 Same as leafref value in model, if applicable.";
243 grouping internal-link-name {
244 leaf internal-link-name {
248 "Internal Link identifier. Unique within the context of a device.
249 Same as leafref value in model, if applicable.";
253 grouping connection-name {
254 leaf connection-name {
257 "Connection name. Unique within the context of a device.
258 Same as leafref value in model, if applicable.";
262 grouping degree-number {
266 "Degree identifier. Unique within the context of a device.
267 Same as leafref value in model, if applicable.";
271 grouping srg-number {
275 "Shared Risk Group identifier. Unique within the context of a device.
276 Same as leafref value in model, if applicable.";
280 grouping shelf-name {
285 "Shelf-id identifier. Unique within the context of a device.
286 Same as leafref value in model, if applicable.";
290 grouping service-name {
295 "Service identifier. Unique within the context of a network.
296 Same as leafref value in model, if applicable.";
300 grouping versioned-service-name {
301 leaf versioned-service-name {
305 "Service identifier. Unique within the context of a network.
306 Same as leafref value in model, if applicable.";
308 leaf version-number {
312 "version-number of the service";
316 grouping temp-service-name {
321 "Service identifier. Unique within the context of a network.
322 Same as leafref value in model, if applicable.";
326 grouping interface-name {
327 leaf interface-name {
331 "Interface identifier.";
335 grouping other-resource-id {
336 leaf other-resource-id {
340 "resource-id for other.";
344 grouping odu-sncp-pg-name {
345 leaf odu-sncp-pg-name {
349 "name of the odu-snc-pg";
353 grouping amp-number {
358 "number of the line-amplifier";
362 grouping xpdr-number {
367 "number of the xponder";