Add WG4 yangs published 2023-03 (v11)
[scp/oam/modeling.git] / data-model / yang / published / o-ran / ru-fh / o-ran-supervision@2022-12-05.yang
diff --git a/data-model/yang/published/o-ran/ru-fh/o-ran-supervision@2022-12-05.yang b/data-model/yang/published/o-ran/ru-fh/o-ran-supervision@2022-12-05.yang
new file mode 100644 (file)
index 0000000..e80b1f8
--- /dev/null
@@ -0,0 +1,370 @@
+module o-ran-supervision {
+  yang-version 1.1;
+  namespace "urn:o-ran:supervision:1.0";
+  prefix "o-ran-supervision";
+
+  import ietf-yang-types {
+    prefix yang;
+  }
+
+  import o-ran-wg4-features {
+    prefix or-feat;
+  }
+
+  import ietf-inet-types {
+    prefix "inet";
+  }
+  import ietf-netconf-monitoring {
+    prefix ncm;
+  }
+
+
+  import o-ran-usermgmt {
+    prefix "or-user";
+  }
+
+  organization "O-RAN Alliance";
+
+  contact
+    "www.o-ran.org";
+
+  description
+    "This module defines the configuration data and supervision RPCs that are
+    used to detect loss M-Plane connectivity.
+
+    Copyright 2021 the O-RAN Alliance.
+
+    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
+    AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+    IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+    ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
+    LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+    CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+    SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+    INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+    CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+    ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+    POSSIBILITY OF SUCH DAMAGE.
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted provided that the following conditions are met:
+
+    * Redistributions of source code must retain the above copyright notice,
+    this list of conditions and the above disclaimer.
+    * Redistributions in binary form must reproduce the above copyright notice,
+    this list of conditions and the above disclaimer in the documentation
+    and/or other materials provided with the distribution.
+    * Neither the Members of the O-RAN Alliance nor the names of its
+    contributors may be used to endorse or promote products derived from
+    this software without specific prior written permission.";
+
+  revision "2022-12-05" {
+    description
+      "version 11.0.0
+
+      1) NETCONF session supervison with session id";
+
+    reference "ORAN-WG4.M.0-v11.00";
+  }
+
+  revision "2022-08-15" {
+    description
+      "version 10.0.0
+
+      1) introduced SHARED-ORU-MULTI-ODU and SHARED-ORU-MULTI-OPERATOR features.";
+
+    reference "ORAN-WG4.M.0-v10.00";
+  }
+
+  revision "2021-12-01" {
+    description
+      "version 5.2.0
+
+      1) typographical corrections in descriptions.";
+
+    reference "ORAN-WG4.M.0-v05.00";
+  }
+
+  revision "2021-03-22" {
+    description
+      "version 5.1.0
+
+      1) typographical corrections in descriptions.
+      2) removed non-ACSII characters.";
+
+    reference "ORAN-WG4.M.0-v05.00";
+  }
+
+  revision "2020-12-10" {
+    description
+      "version 5.0.0
+
+      1) added Event Producer-Collector supervision";
+
+    reference "ORAN-WG4.M.0-v05.00";
+  }
+
+  revision "2020-04-17" {
+    description
+      "version 3.0.0
+
+      1) added output string to enable indication if config modification change has failed
+      2) corrected model description
+      3) removed erroneous text in notification description";
+
+    reference "ORAN-WG4.M.0-v03.00";
+  }
+
+  revision "2019-07-03" {
+    description
+      "version 2.0.0
+
+      1) added leafs for CU plane monitoring
+      2) backward compatible changes to introduce groupings";
+
+    reference "ORAN-WG4.M.0-v01.00";
+  }
+
+  revision "2019-02-04" {
+    description
+      "version 1.0.0
+
+      1) imported model from xRAN
+      2) changed namespace and reference from xran to o-ran";
+
+    reference "ORAN-WG4.M.0-v01.00";
+  }
+
+
+
+
+  typedef event-collector-id {
+    type union {
+      type inet:ip-address;
+      type inet:uri;
+    }
+    description "An Event Collector identifier";
+  }
+
+  grouping watchdog-input {
+    description "a watchdog input grouping";
+    leaf supervision-notification-interval {
+      type uint16;
+      units seconds;
+      default 60;
+      description
+        "The interval in seconds at which supervision notifications are sent.
+        If not specified the default value of 60 seconds shall apply.";
+    }
+    leaf guard-timer-overhead {
+      type uint16;
+      units seconds;
+      default 10;
+      description
+        "This is overhead added to the supervision timer used to calculate the
+         supervision watchdog timer. i.e.,
+
+         supervision timer = notification timer + guard-timer-overhead
+
+         If not specified the default value of 10 seconds shall apply.
+
+         Failure to send this RPC again within the timeout sets the radio into
+         'loss of supervision' state.
+
+         NOTE - The supervision timer MUST not be less that the confirmed
+         timeout timer (when the feature is supported).
+
+         This type of constraint (using an RPC's input) cannot be formally
+         expressed in YANG.";
+    }
+  }
+
+  grouping watchdog-output {
+    description "a watchdog output grouping";
+    leaf next-update-at {
+      type yang:date-and-time;
+      description
+        "Indicates the time when the next supervision notification is expected.";
+    }
+
+    leaf error-message {
+      type string;
+
+      description
+        "An optional error message, e.g., used when the RPC input attempts to
+        modify a locked running configuration.
+
+        Take note, the supervision-notification-interval and guard-timer-overhead
+        have default values and so their values can be modified even when a leaf is
+        not included in the RPC input.";
+    }
+  }
+
+  grouping supervision-notification-data {
+    description "a supervision notification data grouping";
+    leaf session-id {
+      if-feature or-feat:SUPERVISION-WITH-SESSION-ID;
+      type leafref {
+        path "/ncm:netconf-state/ncm:sessions/ncm:session/ncm:session-id";
+      }
+      mandatory true;
+      description
+        "This value uniquely identifies the NETCONF session in an O-RU. The value is conveyed to NETCONF client in hello message.
+        the session-id for the netconf session is sent as part of each supervision-notification notification.
+        and may be used for create-subscription to filter the relevant
+        notifications";
+    }
+  }
+
+  grouping supervision-group {
+    description "a supervision grouping";
+    container cu-plane-monitoring {
+      presence
+        "Indicates O-RU supports timer based cu-plane monitoring interval. If
+        this container is NOT present, the operation of the O-RU is undefined.";
+      description "container describing operation of CU plane monitoring";
+
+      leaf configured-cu-monitoring-interval {
+        type uint8 {
+          range "0..160";
+        }
+        units milliseconds;
+        default 160;
+        description
+          "This value corresponds to the configured value of the timer used by
+          the O-RU to monitor the C/U plane connection.
+
+          A value of 0 means that the O-RU's shall disable its CU plane
+          monitoring.
+
+          A NETCONF client should configure the value according to the
+          configuration of the PHY layer and/or C/U plane section types
+          supported and/or any fault tolerant operation. For example,
+
+          i) when operating with an O-DU supporting non-LAA LTE, this value can
+          be configured to a value according to the repetition time of
+          transmitted reference symbols across the fronthaul interface
+          ii) when operating with an O-DU supporting C-Plane Section Type 0,
+          this value can configured to a value according to the minimum
+          repetition interval of section type 0.
+          iii) when operating with an O-DU supporting fault tolerant operation,
+          this value can be configured according to the fault tolerant heartbeat
+          interval ";
+      }
+    }
+    container event-collector-monitoring {
+      if-feature "or-feat:NON-PERSISTENT-MPLANE";
+      description "container describing operation of Event Collector monitoring";
+
+      leaf heartbeat-interval {
+        type uint8;
+        units seconds;
+        default 60;
+        description "the heartbeat interval";
+      }
+
+      leaf-list heartbeat-recipient-id {
+        type event-collector-id;
+        description
+          "A configured Event collector identity, to which the O-RU shall send heartbeat notifications";
+      }
+    }
+    container per-odu-monitoring {
+      if-feature "or-feat:SHARED-ORU-MULTI-ODU or or-feat:SHARED-ORU-MULTI-OPERATOR";
+      presence
+      "Indicates at least one of the O-RU Controllers intends to operate per O-DU supervision.";
+      description "container describing per-odu monitoring parameters";
+
+      list odu-ids {
+        if-feature or-feat:SHARED-ORU-MULTI-ODU;
+        key odu-id;
+        description
+          "an optional list of o-du identities that an O-RU controller intends to use with per
+          O-DU supervision in a single operator envrionment. The odu-id values are used to match
+          values received in the supervision-watchdog-reset rpc together with values configured in
+          o-ran-uplane-conf based configuration.
+          The O-RU does not further interpret the specific value of odu-id.";
+        leaf odu-id {
+          type string;
+          description "an o-du identity ";
+        }
+      }
+
+      list sro-ids-and-odu-ids {
+        if-feature "or-feat:SHARED-ORU-MULTI-ODU and or-feat:SHARED-ORU-MULTI-OPERATOR";
+        key "odu-id sro-id";
+        description
+          "an optional list of sro and o-du identities that an O-RU controller intends to use with per
+          O-DU supervision in a multi-operator envrionment. The sro-id and odu-id values are used to match
+          values received in the supervision-watchdog-reset rpc together with values configured in
+          o-ran-uplane-conf based configuration.
+          The O-RU does not further interpret the specific value of sro-id or odu-id.";
+        leaf odu-id {
+          type string;
+          description "an o-du identity ";
+        }
+        leaf sro-id {
+          type string;
+          description "an sro identity ";
+        }
+      }
+    }
+  }
+
+  container supervision {
+    description "top leval supervision container";
+    uses supervision-group;
+    // other WG specific monitoring containers follow here
+  }
+
+  rpc supervision-watchdog-reset {
+    description
+      "rpc to reset the watchdog timer";
+    input {
+      uses watchdog-input;
+
+      container context {
+        if-feature "or-feat:SHARED-ORU-MULTI-ODU or or-feat:SHARED-ORU-MULTI-OPERATOR";
+        description
+          "an optional container that defines the context associated with the
+          watchdog reset. Context can be used in supervision operations with
+          multiple O-DUs";
+
+        leaf odu-id {
+          if-feature or-feat:SHARED-ORU-MULTI-ODU;
+          type string;
+          description
+            "an optional o-du identity associated with this
+            supervision watchdog operation. If an odu-id received is not configured
+            in the list of tx-array-carriers or list of rx-array carriers, this leaf is ignored.
+            When it does correspond to an odu-id listed in tx-array-carriers and/or
+            rx-array-carriers, the odu-id is used in the operatrion of per O-DU supervision.";
+        }
+
+        leaf sro-id {
+          if-feature or-feat:SHARED-ORU-MULTI-OPERATOR;
+          type leafref {
+            path "/or-user:users/or-user:user/or-user:sro-id";
+          }
+          description
+            "The shared resource identity associated with the current NETCONF session.
+            A supervision-watchdog-reset RPC received from  NETCONF client
+            with user-group privileges of 'carrier' MUST be rejected
+            if it is received without a sro-id leaf.
+            In other scenarios, this leaf is optional and ignored by the O-RU.";
+        }
+      }
+    }
+
+    output {
+      uses watchdog-output;
+    }
+  }
+
+  notification supervision-notification {
+    description
+      "Notification to indicate that NETCONF management interface is up.";
+      uses supervision-notification-data;
+
+  }
+}