1 module org-openroadm-pm {
2 namespace "http://org/openroadm/pm";
3 prefix org-openroadm-pm;
5 import ietf-yang-types {
7 revision-date 2013-07-15;
9 import org-openroadm-common-types {
10 prefix org-openroadm-common-types;
11 revision-date 2018-10-19;
13 import org-openroadm-resource {
14 prefix org-openroadm-resource;
15 revision-date 2018-10-19;
17 import org-openroadm-resource-types {
18 prefix org-openroadm-resource-types;
19 revision-date 2018-10-19;
21 import org-openroadm-pm-types {
22 prefix org-openroadm-pm-types;
23 revision-date 2017-12-15;
31 "YANG definitions of performance management.
33 Copyright of the Members of the Open ROADM MSA Agreement dated (c) 2016,
34 AT&T Intellectual Property. All other rights reserved.
36 Redistribution and use in source and binary forms, with or without modification,
37 are permitted provided that the following conditions are met:
39 * Redistributions of source code must retain the above copyright notice, this
40 list of conditions and the following disclaimer.
41 * Redistributions in binary form must reproduce the above copyright notice,
42 this list of conditions and the following disclaimer in the documentation and/or
43 other materials provided with the distribution.
44 * Neither the Members of the Open ROADM MSA Agreement nor the names of its
45 contributors may be used to endorse or promote products derived from this software
46 without specific prior written permission.
48 THIS SOFTWARE IS PROVIDED BY THE MEMBERS OF THE OPEN ROADM MSA AGREEMENT ''AS IS''
49 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
50 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
51 IN NO EVENT THE MEMBERS OF THE OPEN ROADM MSA AGREEMENT BE LIABLE FOR ANY DIRECT,
52 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
53 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
54 OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
55 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
56 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
57 POSSIBILITY OF SUCH DAMAGE";
73 "Version 2.0.1 - added revision-date to imports";
84 grouping current-pm-group {
86 "PM Data with current values - both realtime (granularity=notApplicable)
87 and binned (granularity=15 minute, 24h))";
88 leaf pm-resource-instance {
89 type instance-identifier;
93 "Retrieves all PM associate with the resource instance";
95 leaf pm-resource-type {
96 type org-openroadm-resource-types:resource-type-enum;
100 "The supported pm-resource-type associated with the given resource instance.";
102 leaf pm-resource-type-extension {
106 "The resource type extension when the type is not defined in the resource-type-enum.";
108 leaf retrieval-time {
109 type yang:date-and-time;
113 "Represents the time when the data is being read, not the bin start or end time.";
116 key "type extension location direction";
118 uses current-pm-val-group;
122 grouping current-pm-val-group {
123 uses org-openroadm-pm-types:pm-names;
125 type org-openroadm-common-types:location;
128 type org-openroadm-common-types:direction;
133 type org-openroadm-pm-types:pm-granularity;
135 uses org-openroadm-pm-types:pm-measurement;
139 grouping historical-pm-group {
141 "PM Data with historical values - binned (granularity=15 minute, 24h))";
142 leaf pm-resource-instance {
143 type instance-identifier;
147 "Retrieves all PM associate with the resource instance";
149 leaf pm-resource-type {
150 type org-openroadm-resource-types:resource-type-enum;
154 leaf pm-resource-type-extension {
158 "The resource type extension when the type is not defined in the resource-type-enum.";
161 key "type extension location direction";
162 uses historical-pm-val-group;
166 grouping historical-pm-val-group {
168 "PM Data with historical values";
169 uses org-openroadm-pm-types:pm-names;
171 type org-openroadm-common-types:location;
174 type org-openroadm-common-types:direction;
177 key "granularity bin-number";
179 type org-openroadm-pm-types:pm-granularity;
189 uses org-openroadm-pm-types:pm-measurement;
190 leaf completion-time {
191 type yang:date-and-time;
195 "The time at the end of the period; For example if bin starts at
196 01:15:00 and ends at 01:29:59, the completion-time is 01:29:59";
201 grouping collect-history-pm-group {
207 "The file name to write the historical PM data.
208 The controller should be able to use this name to retrieve the file via ftp/sftp.
209 The file name should be unique for each RPC request since a new RPC request
210 could be initiated while the file transfer of the previous file is still in progress.
212 The file content should be written in xml format based on the historical-pm-list
213 yang definition and the file should be gzip compressed.";
215 uses org-openroadm-common-types:rpc-response-status;
220 "Command to initialize PM data";
222 uses org-openroadm-resource:resource;
235 type org-openroadm-pm-types:pm-granularity;
240 uses org-openroadm-common-types:rpc-response-status;
243 rpc collect-historical-pm-file {
245 "Command to query historical PM data.
246 The device should be able to process an rpc request for 15min data
247 and a separate request for 24hour data in parallel.";
249 leaf from-bin-number {
255 "The start bin-number of the range";
263 "The end bin-number of the range";
266 type org-openroadm-pm-types:pm-granularity;
269 "The granularity of the retrieve, default to 15 minitues PM";
273 uses collect-history-pm-group;
276 notification historical-pm-collect-result {
278 "This Notification is sent when the pm collection is succesful or failed.";
279 uses collect-history-pm-group;
281 container current-pm-list {
284 "List of current PMs.";
285 list current-pm-entry {
286 key "pm-resource-type pm-resource-type-extension pm-resource-instance";
287 uses current-pm-group;
290 container historical-pm-list {
293 "List of historical PM";
294 list historical-pm-entry {
295 key "pm-resource-type pm-resource-type-extension pm-resource-instance";
296 uses historical-pm-group;