Openroadm models update
[transportpce.git] / ordmodels / network / src / main / yang / org-openroadm-link@2017-09-29.yang
1 module org-openroadm-link {
2   namespace "http://org/openroadm/link";
3   prefix link;
4
5   import org-openroadm-common-types {
6     prefix org-openroadm-common-types;
7     revision-date 2017-09-29;
8   }
9   import org-openroadm-amplifier {
10     prefix org-openroadm-amplifier;
11     revision-date 2017-09-29;
12   }
13
14   organization
15     "Open ROADM MSA";
16   contact
17     "OpenROADM.org.";
18   description
19     "YANG definitions for an amplifier in Network Model
20
21
22      Copyright of the Members of the Open ROADM MSA Agreement dated (c) 2017,
23      AT&T Intellectual Property.  All other rights reserved.
24
25      Redistribution and use in source and binary forms, with or without modification,
26      are permitted provided that the following conditions are met:
27
28      * Redistributions of source code must retain the above copyright notice, this
29        list of conditions and the following disclaimer.
30      * Redistributions in binary form must reproduce the above copyright notice,
31        this list of conditions and the following disclaimer in the documentation and/or
32        other materials provided with the distribution.
33      * Neither the Members of the Open ROADM MSA Agreement nor the names of its
34        contributors may be used to endorse or promote products derived from this software
35        without specific prior written permission.
36
37      THIS SOFTWARE IS PROVIDED BY THE MEMBERS OF THE OPEN ROADM MSA  AGREEMENT ''AS IS''
38      AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
39      WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
40      IN NO EVENT THE MEMBERS OF THE OPEN ROADM MSA  AGREEMENT BE LIABLE FOR ANY DIRECT,
41      INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
42      NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;  LOSS OF USE, DATA,
43      OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
44      WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
45      ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
46      POSSIBILITY OF SUCH DAMAGE.";
47
48   revision 2017-09-29 {
49     description
50       "Version 2.1";
51   }
52   revision 2017-07-28 {
53     description
54       "Version 2.0.1 - added revision-date to imports";
55   }
56   revision 2017-06-17 {
57     description
58       "Version 2.0";
59   }
60
61   grouping OMS-attributes {
62     leaf TE-metric {
63       type uint32;
64     }
65   }
66
67   grouping span-attributes {
68     leaf clfi  {
69       type string;
70     }
71     leaf auto-spanloss {
72       type boolean;
73       default "true";
74       description
75         "Flag to enable/disable automatic spanloss measurement";
76     }
77     leaf spanloss-base {
78       type org-openroadm-common-types:ratio-dB;
79       description
80         "Baseline ROADM span loss measured and accepted during
81          degree turn-up.";
82     }
83     leaf spanloss-current {
84       type org-openroadm-common-types:ratio-dB;
85       description
86         "Current ROADM span loss measured and accepted during
87          degree turn-up.";
88     }
89     leaf engineered-spanloss {
90       type org-openroadm-common-types:ratio-dB;
91       description
92         "ROADM span loss provided by an external system";
93     }
94     list link-concatenation {
95       key "SRLG-Id";
96       leaf SRLG-Id {
97         type uint32;
98         description
99           "unique identifier for SRLG";
100       }
101       leaf fiber-type {
102         type enumeration {
103           enum "smf" {
104             value 0;
105             description
106               "Single Mode Fiber";
107           }
108           enum "eleaf" {
109             value 1;
110             description
111               "ELEAF";
112           }
113           enum "oleaf" {
114             value 2;
115             description
116               "OLEAF";
117           }
118           enum "dsf" {
119             value 3;
120             description
121               "DSF";
122           }
123           enum "truewave" {
124             value 4;
125             description
126               "TRUEWAVE Reduced Slope";
127           }
128           enum "truewavec" {
129             value 5;
130             description
131               "TRUEWAVE Classic";
132           }
133           enum "nz-dsf" {
134             value 6;
135             description
136               "NZ-DSF";
137           }
138           enum "ull" {
139             value 7;
140             description
141               "Ultra Low Loss (ULL)";
142           }
143         }
144       }
145       leaf SRLG-length {
146         type uint32;
147         description
148           "fiber length in meters";
149       }
150       leaf pmd {
151         type org-openroadm-common-types:fiber-pmd;
152         description
153           "Total PMD";
154       }
155     }
156   }
157
158   grouping amplified-link-attributes {
159     list amplified-link {
160       description
161         "defines the spans and the amplifier blocks of the amplified lines";
162       key "section-elt-number";
163       leaf section-elt-number {
164         type uint16;
165         description
166           "Id of the section element (whether it's a Span or an Amp)";
167       }
168       container section-element {
169         choice section-element {
170           case ila {
171             container ila {
172               uses org-openroadm-amplifier:amplifier-node-attributes;
173               leaf node-id {
174                 type org-openroadm-common-types:node-id-type;
175                 mandatory true;
176                 description
177                   "Node id corresponding to the amplifier ";
178               }
179               leaf administrative-state {
180                 type org-openroadm-common-types:state;
181                 description
182                   "according to RFC3630 definition";
183               }
184             }
185           }
186           case span {
187             container span {
188               uses link:span-attributes;
189               leaf administrative-state {
190                 type org-openroadm-common-types:state;
191                 description
192                   "according to RFC3630 definition";
193               }
194             }
195           }
196         }
197       }
198     }
199   }
200 }