Reorganization of devicemanager directory structure
[ccsdk/features.git] / sdnr / wt / devicemanager-onap / onf14 / provider / src / main / yang / qos-profile-1-0.yang
diff --git a/sdnr/wt/devicemanager-onap/onf14/provider/src/main/yang/qos-profile-1-0.yang b/sdnr/wt/devicemanager-onap/onf14/provider/src/main/yang/qos-profile-1-0.yang
new file mode 100644 (file)
index 0000000..7dd05d0
--- /dev/null
@@ -0,0 +1,534 @@
+module qos-profile-1-0 {\r
+  yang-version 1.1;\r
+  namespace "urn:onf:yang:qos-profile-1-0";\r
+  prefix qos-profile;\r
+\r
+  import ietf-yang-types {\r
+    prefix yang;\r
+  }\r
+  import core-model-1-4 {\r
+    prefix core-model;\r
+  }\r
+\r
+  organization\r
+    "openBackhaul.com proposal to Open Networking Foundation (ONF)";\r
+  contact\r
+    "WG Web : https://github.com/openBackhaul/Overview\r
+     WG List: QosProfile@openBackhaul.com\r
+     Editor : Thorsten Heinze\r
+     Email  : Thorsten.Heinze@openBackhaul.com";\r
+  description\r
+    "Copyright 2019 openBackhaul.com\r
+\r
+     Licensed under the Apache License, Version 2.0 (the 'License');\r
+     you may not use this file except in compliance with the License.\r
+     You may obtain a copy of the License at\r
+     http://www.apache.org/licenses/LICENSE-2.0\r
+     Unless required by applicable law or agreed to in writing, software\r
+     distributed under the License is distributed on an 'AS IS' BASIS,\r
+     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+     See the License for the specific language governing permissions and\r
+     limitations under the License.";\r
+\r
+  revision 2020-01-24 {\r
+    description\r
+      "Model for the Transport SDN Pilot at Telefonica Germany.\r
+       Please view https://github.com/openBackhaul/qosProfile/issues for changes.";\r
+    reference\r
+      "https://github.com/openBackhaul/qosProfile/tree/tsp: Model definition\r
+       https://github.com/openBackhaul/onfCoreIm/tree/tsp: ONF TR-512 Core IM incl. Profile and enhanced Equipment definition";\r
+  }\r
+  revision 2019-07-12 {\r
+    description\r
+      "Model for the Transport SDN Pilot at Telefonica Germany.\r
+       Please view https://github.com/openBackhaul/qosProfile/issues for changes.";\r
+    reference\r
+      "https://github.com/openBackhaul/qosProfile/tree/tsp: Model definition\r
+       https://github.com/openBackhaul/onfCoreIm/tree/tsp: ONF TR-512 Core IM incl. Profile and enhanced Equipment definition";\r
+  }\r
+\r
+  identity PROFILE_NAME_TYPE_QOS_PROFILE {\r
+    base core-model:PROFILE_NAME_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  augment "/core-model:control-construct/core-model:profile-collection/core-model:profile" {\r
+    when "derived-from-or-self(./core-model:profile-name, 'qos-profile:PROFILE_NAME_TYPE_QOS_PROFILE')";\r
+    uses qos-profile-spec;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  /****************************************\r
+   * package notifications\r
+   **************************************/ \r
+\r
+  notification object-creation-notification {\r
+    uses object-creation-notification;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  grouping object-creation-notification {\r
+    leaf counter {\r
+      type int32;\r
+      default "-1";\r
+      config false;\r
+      description\r
+        "Counts object creation notifications.";\r
+    }\r
+    leaf timestamp {\r
+      type yang:date-and-time;\r
+      default "2010-11-20T14:00:00+01:00";\r
+      config false;\r
+      description\r
+        "none";\r
+    }\r
+    leaf object-id-ref {\r
+      type leafref {\r
+        path "/core-model:control-construct/core-model:profile-collection/core-model:profile/core-model:uuid";\r
+        require-instance false;\r
+      }\r
+      config false;\r
+      description\r
+        "none";\r
+    }\r
+    leaf object-type {\r
+      type string;\r
+      default "Type of created object not specified.";\r
+      config false;\r
+      description\r
+        "none";\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  notification object-deletion-notification {\r
+    uses object-deletion-notification;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  grouping object-deletion-notification {\r
+    leaf counter {\r
+      type int32;\r
+      default "-1";\r
+      config false;\r
+      description\r
+        "Counts object deletion notifications.";\r
+    }\r
+    leaf timestamp {\r
+      type yang:date-and-time;\r
+      default "2010-11-20T14:00:00+01:00";\r
+      config false;\r
+      description\r
+        "none";\r
+    }\r
+    leaf object-id-ref {\r
+      type leafref {\r
+        path "/core-model:control-construct/core-model:profile-collection/core-model:profile/core-model:uuid";\r
+        require-instance false;\r
+      }\r
+      config false;\r
+      description\r
+        "none";\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  /****************************************\r
+   * grouping statements for object classes\r
+   **************************************/ \r
+\r
+  grouping qos-profile-spec {\r
+    container qos-profile-pac {\r
+      uses qos-profile-pac;\r
+      description\r
+        "none";\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  grouping qos-profile-pac {\r
+    container qos-profile-capability {\r
+      config false;\r
+      uses qos-profile-capability;\r
+      description\r
+        "none";\r
+    }\r
+    container qos-profile-configuration {\r
+      config false;\r
+      uses qos-profile-configuration;\r
+      description\r
+        "none";\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  grouping qos-profile-capability {\r
+    leaf profile-naming-is-avail {\r
+      type boolean;\r
+      default "false";\r
+      config false;\r
+      description\r
+        "1 = There is a free text field available for naming the profile.";\r
+    }\r
+    leaf-list available-queue-list {\r
+      type queue-name-type;\r
+      config false;\r
+      min-elements 1;\r
+      max-elements 8;\r
+      description\r
+        "List of queues, which are available at the physical interface.";\r
+    }\r
+    leaf drop-precedence-at-be-queue-is-avail {\r
+      type boolean;\r
+      default "false";\r
+      config false;\r
+      description\r
+        "1 = Configuration of the drop precedence is available at the best effort queue.";\r
+    }\r
+    leaf drop-precedence-at-af-queues-is-avail {\r
+      type boolean;\r
+      default "false";\r
+      config false;\r
+      description\r
+        "1 = Configuration of the drop precedence is available at the assured forwarding queues.";\r
+    }\r
+    leaf drop-precedence-at-prio-queues-is-avail {\r
+      type boolean;\r
+      default "false";\r
+      config false;\r
+      description\r
+        "1 = Configuration of the drop precedence is available at the priority queues.";\r
+    }\r
+    leaf available-qos-profile-kind-list {\r
+      type qos-profile-kind-type;\r
+      default "QOS_PROFILE_KIND_TYPE_NOT_YET_DEFINED";\r
+      config false;\r
+      description\r
+        "List of header information that are supported to be base of the QoS definition.";\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  grouping qos-profile-configuration {\r
+    leaf profile-name {\r
+      type string;\r
+      default "Name of profile not yet defined.";\r
+      description\r
+        "Identifier of the profile. Could be a name, could be a number. Free text field to be filled by the operator.";\r
+    }\r
+    leaf qos-profile-kind {\r
+      type qos-profile-kind-type;\r
+      default "QOS_PROFILE_KIND_TYPE_NOT_YET_DEFINED";\r
+      description\r
+        "Defines whether the sorting into queues is done based on VLAN, MPLS or IP header information.";\r
+    }\r
+    list ingress-8021p-to-per-hop-behavior-mapping-list {\r
+      key "queue-name drop-precedence-inside-queue";\r
+      min-elements 8;\r
+      max-elements 8;\r
+      uses per-hop-behavior-type;\r
+      description\r
+        "Only relevant when qosProfileKind == IEEE8021P. Associates the value of the three p-bits of the VLAN header with a per hop behavior at the physical interface. First entry in the list [0] relates to p-bit value '0'. Last entry in the list [7] relates to p-bit value '7'.";\r
+    }\r
+    list ingress-exp-to-per-hop-behavior-mapping-list {\r
+      key "queue-name drop-precedence-inside-queue";\r
+      min-elements 8;\r
+      max-elements 8;\r
+      uses per-hop-behavior-type;\r
+      description\r
+        "Only relevant when qosProfileKind == MPLS_EXP. Associates the value of the three p-bits of the MPLS header with a per hop behavior at the physical interface. First entry in the list [0] relates to p-bit value '0'. Last entry in the list [7] relates to p-bit value '7'.";\r
+    }\r
+    list ingress-ip-dscp-to-per-hop-behavior-mapping-list {\r
+      key "queue-name drop-precedence-inside-queue";\r
+      min-elements 64;\r
+      max-elements 64;\r
+      uses per-hop-behavior-type;\r
+      description\r
+        "Only relevant when qosProfileKind == IP_DSCP. Associates the value of the 8 dscp bits of the IP header with a per hop behavior at the physical interface. First entry in the list [0] relates to dscp value '0'. Last entry in the list [63] relates to dscp value '63'.";\r
+    }\r
+    leaf writing-per-hop-behavior-into-8021p-is-on {\r
+      type boolean;\r
+      default "false";\r
+      description\r
+        "1 = Original content of 802.1p bits is overwritten with local per hop behavior.";\r
+    }\r
+    list egress-per-hop-behavior-to-8021p-mapping-list {\r
+      key "mapping-number";\r
+      max-elements 24;\r
+      uses egress-per-hop-behavior-to-priority-bits-mapping-type;\r
+      description\r
+        "Only relevant if (writingPerHopBehaviorInto8021pIsOn==1). Translates (queue and drop precedence) into values of the three p-bits of the VLAN header.";\r
+    }\r
+    leaf writing-per-hop-behavior-into-mpls-exp-is-on {\r
+      type boolean;\r
+      default "false";\r
+      description\r
+        "1 = Original content of MPLS EXP bits is overwritten with local per hop behavior.";\r
+    }\r
+    list egress-per-hop-behavior-to-mpls-exp-mapping-list {\r
+      key "mapping-number";\r
+      max-elements 24;\r
+      uses egress-per-hop-behavior-to-priority-bits-mapping-type;\r
+      description\r
+        "Only relevant if (writingPerHopBehaviorIntoMplsExpIsOn==1). Translates (queue and drop precedence) into values of the three p-bits of the MPLS header.";\r
+    }\r
+    leaf writing-per-hop-behavior-into-ip-dscp-is-on {\r
+      type boolean;\r
+      default "false";\r
+      description\r
+        "1 = Original content of IP DSCP bits is overwritten with local per hop behavior.";\r
+    }\r
+    list egress-per-hop-behavior-to-ip-dscp-mapping-list {\r
+      key "mapping-number";\r
+      max-elements 24;\r
+      uses egress-per-hop-behavior-to-priority-bits-mapping-type;\r
+      description\r
+        "Only relevant if (writingPerHopBehaviorIntoIpDscpIsOn==1). Translates (queue and drop precedence) into values of the six dscp bits of the IP header.";\r
+    }\r
+    description\r
+      "Defines the profile that will be used for mapping between header information and queues (next hop behavior).";\r
+  }\r
+\r
+  /****************************************\r
+   * typedef statements\r
+   **************************************/ \r
+\r
+  typedef severity-type {\r
+    type identityref {\r
+      base SEVERITY_TYPE;\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  typedef qos-profile-kind-type {\r
+    type identityref {\r
+      base QOS_PROFILE_KIND_TYPE;\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  typedef queue-name-type {\r
+    type identityref {\r
+      base QUEUE_NAME_TYPE;\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  typedef drop-precedence-type {\r
+    type identityref {\r
+      base DROP_PRECEDENCE_TYPE;\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  /*********************************************\r
+   * grouping statements for complex data types\r
+   *******************************************/ \r
+\r
+  identity SEVERITY_TYPE {\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity SEVERITY_TYPE_NON-ALARMED {\r
+    base SEVERITY_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity SEVERITY_TYPE_WARNING {\r
+    base SEVERITY_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity SEVERITY_TYPE_MAJOR {\r
+    base SEVERITY_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity SEVERITY_TYPE_MINOR {\r
+    base SEVERITY_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity QOS_PROFILE_KIND_TYPE {\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity QOS_PROFILE_KIND_TYPE_NONE {\r
+    base QOS_PROFILE_KIND_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity QOS_PROFILE_KIND_TYPE_IEEE8021P {\r
+    base QOS_PROFILE_KIND_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity QOS_PROFILE_KIND_TYPE_MPLS_EXP {\r
+    base QOS_PROFILE_KIND_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity QOS_PROFILE_KIND_TYPE_IP_DSCP {\r
+    base QOS_PROFILE_KIND_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity QOS_PROFILE_KIND_TYPE_NOT_YET_DEFINED {\r
+    base QOS_PROFILE_KIND_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE {\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_BEST_EFFORT_QUEUE {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "Queue 0.";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_ASSURED_FORWARDING_QUEUE1 {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "Queue 1.";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_ASSURED_FORWARDING_QUEUE2 {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "Queue 2.";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_ASSURED_FORWARDING_QUEUE3 {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "Queue 3.";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_ASSURED_FORWARDING_QUEUE4 {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "Queue 4.";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_EXPEDITED_FORWARDING_QUEUE {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "Queue 5.";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_CLASS_SELECTOR_QUEUE6 {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "Queue 6.";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_CLASS_SELECTOR_QUEUE7 {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "Queue 7.";\r
+  }\r
+\r
+  identity QUEUE_NAME_TYPE_NOT_YET_DEFINED {\r
+    base QUEUE_NAME_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity DROP_PRECEDENCE_TYPE {\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity DROP_PRECEDENCE_TYPE_NONE {\r
+    base DROP_PRECEDENCE_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  identity DROP_PRECEDENCE_TYPE_LOW {\r
+    base DROP_PRECEDENCE_TYPE;\r
+    description\r
+      "Would be equal to GREEN.";\r
+  }\r
+\r
+  identity DROP_PRECEDENCE_TYPE_MEDIUM {\r
+    base DROP_PRECEDENCE_TYPE;\r
+    description\r
+      "Would be equal to YELLOW.";\r
+  }\r
+\r
+  identity DROP_PRECEDENCE_TYPE_HIGH {\r
+    base DROP_PRECEDENCE_TYPE;\r
+    description\r
+      "Would be equal to RED.";\r
+  }\r
+\r
+  identity DROP_PRECEDENCE_TYPE_NOT_YET_DEFINED {\r
+    base DROP_PRECEDENCE_TYPE;\r
+    description\r
+      "none";\r
+  }\r
+\r
+  grouping per-hop-behavior-type {\r
+    leaf queue-name {\r
+      type queue-name-type;\r
+      description\r
+        "Name of the queue.";\r
+    }\r
+    leaf drop-precedence-inside-queue {\r
+      type drop-precedence-type;\r
+      description\r
+        "(if dropPrecedenceAt*QueueIsAvail for the referenced queue == 0) default value shall be kept and configuration attempts shall be ignored.";\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+\r
+  grouping egress-per-hop-behavior-to-priority-bits-mapping-type {\r
+    leaf mapping-number {\r
+      type int16;\r
+      description\r
+        "none";\r
+    }\r
+    container per-hop-behavior {\r
+      uses per-hop-behavior-type;\r
+      description\r
+        "Per hop behavior, which is to be translated into a p-bit entry in the VLAN, MPLS or IP header.";\r
+    }\r
+    leaf value-of-priority-bits {\r
+      type int8;\r
+      default "-1";\r
+      description\r
+        "Associated value of the three, three or six p-bits of the VLAN, MPLS or IP header.";\r
+    }\r
+    description\r
+      "none";\r
+  }\r
+}\r