Support of WG4 OpenFronthaul Management-Plane VES
[scp/oam/modeling.git] / data-model / yang / published / o-ran / ru-fh / o-ran-supervision@2022-12-05.yang
1 module o-ran-supervision {
2   yang-version 1.1;
3   namespace "urn:o-ran:supervision:1.0";
4   prefix "o-ran-supervision";
5
6   import ietf-yang-types {
7     prefix yang;
8   }
9
10   import o-ran-wg4-features {
11     prefix or-feat;
12   }
13
14   import ietf-inet-types {
15     prefix "inet";
16   }
17   import ietf-netconf-monitoring {
18     prefix ncm;
19   }
20
21
22   import o-ran-usermgmt {
23     prefix "or-user";
24   }
25
26   organization "O-RAN Alliance";
27
28   contact
29     "www.o-ran.org";
30
31   description
32     "This module defines the configuration data and supervision RPCs that are
33     used to detect loss M-Plane connectivity.
34
35     Copyright 2021 the O-RAN Alliance.
36
37     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
38     AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
39     IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
40     ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
41     LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
42     CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
43     SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
44     INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
45     CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
46     ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
47     POSSIBILITY OF SUCH DAMAGE.
48
49     Redistribution and use in source and binary forms, with or without
50     modification, are permitted provided that the following conditions are met:
51
52     * Redistributions of source code must retain the above copyright notice,
53     this list of conditions and the above disclaimer.
54     * Redistributions in binary form must reproduce the above copyright notice,
55     this list of conditions and the above disclaimer in the documentation
56     and/or other materials provided with the distribution.
57     * Neither the Members of the O-RAN Alliance nor the names of its
58     contributors may be used to endorse or promote products derived from
59     this software without specific prior written permission.";
60
61   revision "2022-12-05" {
62     description
63       "version 11.0.0
64
65       1) NETCONF session supervison with session id";
66
67     reference "ORAN-WG4.M.0-v11.00";
68   }
69
70   revision "2022-08-15" {
71     description
72       "version 10.0.0
73
74       1) introduced SHARED-ORU-MULTI-ODU and SHARED-ORU-MULTI-OPERATOR features.";
75
76     reference "ORAN-WG4.M.0-v10.00";
77   }
78
79   revision "2021-12-01" {
80     description
81       "version 5.2.0
82
83       1) typographical corrections in descriptions.";
84
85     reference "ORAN-WG4.M.0-v05.00";
86   }
87
88   revision "2021-03-22" {
89     description
90       "version 5.1.0
91
92       1) typographical corrections in descriptions.
93       2) removed non-ACSII characters.";
94
95     reference "ORAN-WG4.M.0-v05.00";
96   }
97
98   revision "2020-12-10" {
99     description
100       "version 5.0.0
101
102       1) added Event Producer-Collector supervision";
103
104     reference "ORAN-WG4.M.0-v05.00";
105   }
106
107   revision "2020-04-17" {
108     description
109       "version 3.0.0
110
111       1) added output string to enable indication if config modification change has failed
112       2) corrected model description
113       3) removed erroneous text in notification description";
114
115     reference "ORAN-WG4.M.0-v03.00";
116   }
117
118   revision "2019-07-03" {
119     description
120       "version 2.0.0
121
122       1) added leafs for CU plane monitoring
123       2) backward compatible changes to introduce groupings";
124
125     reference "ORAN-WG4.M.0-v01.00";
126   }
127
128   revision "2019-02-04" {
129     description
130       "version 1.0.0
131
132       1) imported model from xRAN
133       2) changed namespace and reference from xran to o-ran";
134
135     reference "ORAN-WG4.M.0-v01.00";
136   }
137
138
139
140
141   typedef event-collector-id {
142     type union {
143       type inet:ip-address;
144       type inet:uri;
145     }
146     description "An Event Collector identifier";
147   }
148
149   grouping watchdog-input {
150     description "a watchdog input grouping";
151     leaf supervision-notification-interval {
152       type uint16;
153       units seconds;
154       default 60;
155       description
156         "The interval in seconds at which supervision notifications are sent.
157         If not specified the default value of 60 seconds shall apply.";
158     }
159     leaf guard-timer-overhead {
160       type uint16;
161       units seconds;
162       default 10;
163       description
164         "This is overhead added to the supervision timer used to calculate the
165          supervision watchdog timer. i.e.,
166
167          supervision timer = notification timer + guard-timer-overhead
168
169          If not specified the default value of 10 seconds shall apply.
170
171          Failure to send this RPC again within the timeout sets the radio into
172          'loss of supervision' state.
173
174          NOTE - The supervision timer MUST not be less that the confirmed
175          timeout timer (when the feature is supported).
176
177          This type of constraint (using an RPC's input) cannot be formally
178          expressed in YANG.";
179     }
180   }
181
182   grouping watchdog-output {
183     description "a watchdog output grouping";
184     leaf next-update-at {
185       type yang:date-and-time;
186       description
187         "Indicates the time when the next supervision notification is expected.";
188     }
189
190     leaf error-message {
191       type string;
192
193       description
194         "An optional error message, e.g., used when the RPC input attempts to
195         modify a locked running configuration.
196
197         Take note, the supervision-notification-interval and guard-timer-overhead
198         have default values and so their values can be modified even when a leaf is
199         not included in the RPC input.";
200     }
201   }
202
203   grouping supervision-notification-data {
204     description "a supervision notification data grouping";
205     leaf session-id {
206       if-feature or-feat:SUPERVISION-WITH-SESSION-ID;
207       type leafref {
208         path "/ncm:netconf-state/ncm:sessions/ncm:session/ncm:session-id";
209       }
210       mandatory true;
211       description
212         "This value uniquely identifies the NETCONF session in an O-RU. The value is conveyed to NETCONF client in hello message.
213         the session-id for the netconf session is sent as part of each supervision-notification notification.
214         and may be used for create-subscription to filter the relevant
215         notifications";
216     }
217   }
218
219   grouping supervision-group {
220     description "a supervision grouping";
221     container cu-plane-monitoring {
222       presence
223         "Indicates O-RU supports timer based cu-plane monitoring interval. If
224         this container is NOT present, the operation of the O-RU is undefined.";
225       description "container describing operation of CU plane monitoring";
226
227       leaf configured-cu-monitoring-interval {
228         type uint8 {
229           range "0..160";
230         }
231         units milliseconds;
232         default 160;
233         description
234           "This value corresponds to the configured value of the timer used by
235           the O-RU to monitor the C/U plane connection.
236
237           A value of 0 means that the O-RU's shall disable its CU plane
238           monitoring.
239
240           A NETCONF client should configure the value according to the
241           configuration of the PHY layer and/or C/U plane section types
242           supported and/or any fault tolerant operation. For example,
243
244           i) when operating with an O-DU supporting non-LAA LTE, this value can
245           be configured to a value according to the repetition time of
246           transmitted reference symbols across the fronthaul interface
247           ii) when operating with an O-DU supporting C-Plane Section Type 0,
248           this value can configured to a value according to the minimum
249           repetition interval of section type 0.
250           iii) when operating with an O-DU supporting fault tolerant operation,
251           this value can be configured according to the fault tolerant heartbeat
252           interval ";
253       }
254     }
255     container event-collector-monitoring {
256       if-feature "or-feat:NON-PERSISTENT-MPLANE";
257       description "container describing operation of Event Collector monitoring";
258
259       leaf heartbeat-interval {
260         type uint8;
261         units seconds;
262         default 60;
263         description "the heartbeat interval";
264       }
265
266       leaf-list heartbeat-recipient-id {
267         type event-collector-id;
268         description
269           "A configured Event collector identity, to which the O-RU shall send heartbeat notifications";
270       }
271     }
272     container per-odu-monitoring {
273       if-feature "or-feat:SHARED-ORU-MULTI-ODU or or-feat:SHARED-ORU-MULTI-OPERATOR";
274       presence
275       "Indicates at least one of the O-RU Controllers intends to operate per O-DU supervision.";
276       description "container describing per-odu monitoring parameters";
277
278       list odu-ids {
279         if-feature or-feat:SHARED-ORU-MULTI-ODU;
280         key odu-id;
281         description
282           "an optional list of o-du identities that an O-RU controller intends to use with per
283           O-DU supervision in a single operator envrionment. The odu-id values are used to match
284           values received in the supervision-watchdog-reset rpc together with values configured in
285           o-ran-uplane-conf based configuration.
286           The O-RU does not further interpret the specific value of odu-id.";
287         leaf odu-id {
288           type string;
289           description "an o-du identity ";
290         }
291       }
292
293       list sro-ids-and-odu-ids {
294         if-feature "or-feat:SHARED-ORU-MULTI-ODU and or-feat:SHARED-ORU-MULTI-OPERATOR";
295         key "odu-id sro-id";
296         description
297           "an optional list of sro and o-du identities that an O-RU controller intends to use with per
298           O-DU supervision in a multi-operator envrionment. The sro-id and odu-id values are used to match
299           values received in the supervision-watchdog-reset rpc together with values configured in
300           o-ran-uplane-conf based configuration.
301           The O-RU does not further interpret the specific value of sro-id or odu-id.";
302         leaf odu-id {
303           type string;
304           description "an o-du identity ";
305         }
306         leaf sro-id {
307           type string;
308           description "an sro identity ";
309         }
310       }
311     }
312   }
313
314   container supervision {
315     description "top leval supervision container";
316     uses supervision-group;
317     // other WG specific monitoring containers follow here
318   }
319
320   rpc supervision-watchdog-reset {
321     description
322       "rpc to reset the watchdog timer";
323     input {
324       uses watchdog-input;
325
326       container context {
327         if-feature "or-feat:SHARED-ORU-MULTI-ODU or or-feat:SHARED-ORU-MULTI-OPERATOR";
328         description
329           "an optional container that defines the context associated with the
330           watchdog reset. Context can be used in supervision operations with
331           multiple O-DUs";
332
333         leaf odu-id {
334           if-feature or-feat:SHARED-ORU-MULTI-ODU;
335           type string;
336           description
337             "an optional o-du identity associated with this
338             supervision watchdog operation. If an odu-id received is not configured
339             in the list of tx-array-carriers or list of rx-array carriers, this leaf is ignored.
340             When it does correspond to an odu-id listed in tx-array-carriers and/or
341             rx-array-carriers, the odu-id is used in the operatrion of per O-DU supervision.";
342         }
343
344         leaf sro-id {
345           if-feature or-feat:SHARED-ORU-MULTI-OPERATOR;
346           type leafref {
347             path "/or-user:users/or-user:user/or-user:sro-id";
348           }
349           description
350             "The shared resource identity associated with the current NETCONF session.
351             A supervision-watchdog-reset RPC received from  NETCONF client
352             with user-group privileges of 'carrier' MUST be rejected
353             if it is received without a sro-id leaf.
354             In other scenarios, this leaf is optional and ignored by the O-RU.";
355         }
356       }
357     }
358
359     output {
360       uses watchdog-output;
361     }
362   }
363
364   notification supervision-notification {
365     description
366       "Notification to indicate that NETCONF management interface is up.";
367       uses supervision-notification-data;
368
369   }
370 }