Merge dev/fluorine work across to master
[unimgr.git] / nrp-api / src / main / yang / tapi-topology@2018-03-07.yang
similarity index 78%
rename from nrp-api/src/main/yang/tapi-topology.yang
rename to nrp-api/src/main/yang/tapi-topology@2018-03-07.yang
index fb82a828713cc23aa5e6025dc19b47b03a4eb33b..423ed967a673adb4e3d8098b40b48058f8ff926e 100644 (file)
@@ -1,81 +1,90 @@
 module tapi-topology {
-    namespace "urn:onf:params:xml:ns:yang:tapi-topology";
+    namespace "urn:onf:otcc:yang:tapi-topology";
     prefix tapi-topology;
     import tapi-common {
         prefix tapi-common;
     }
-    organization "ONF (Open Networking Foundation) IMP Working Group";
-    contact "WG Web: <https://www.open{[]}networking.org/technical-communities/areas/services/> 
- WG List: mailto: <wg list name>@opennetworking.org>, 
-.WG Chair: your-WG-chair<mailto:your-WG-chair@example.com> 
-Editor: your-name<mailto:your-email@example.com>";
-    description "none";
-    revision 2017-11-13 {
-        description "TAPI SDK 2.0-alpha";
-        reference "ONF-TR-527, ONF-TR-512, ONF-TR-531, RFC 6020 and RFC 6087";
+    organization "ONF OTCC (Open Transport Configuration & Control) Project";
+    contact "
+        Project Web: <https://wiki.opennetworking.org/display/OTCC/TAPI>
+        Project List: <mailto:transport-api@opennetworking.org>
+        Editor: Karthik Sethuraman
+                <mailto:karthik.sethuraman@necam.com>";
+    description "
+        This module contains TAPI Topology Model definitions.
+        Source: TapiTopology.uml
+        Copyright (c) 2018 Open Networking Foundation (ONF). All rights reserved.
+        License: This module is distributed under the Apache License 2.0";
+    revision 2018-03-07 {
+        description "ONF Transport API version 2.0.2
+        This YANG module has been generated from the TAPI UML Model using the IISOMI-Eagle xmi2yang mapping tool version .
+        <https://wiki.opennetworking.org/display/OIMT/IISOMI>
+        Changes in this revision: <https://github.com/OpenNetworkingFoundation/TAPI/blob/develop/change-log.md>";
+        reference "ONF-TR-527, ONF-TR-512, ONF-TR-531, RFC 6020, RFC 6087 and ONF TAPI UML model
+                  <https://github.com/OpenNetworkingFoundation/TAPI/tree/develop/UML>";
     }
     augment "/tapi-common:context" {
         uses topology-context;
         description "Augments the base TAPI Context with TopologyService information";
     }
-    /***********************
-    * package object-classes
-    **********************/ 
-        grouping link {
-            leaf-list node-edge-point {
-                type leafref {
-                    path '/tapi-common:context/tapi-topology:topology/tapi-topology:node/tapi-topology:owned-node-edge-point/tapi-topology:uuid';
-                }
-                config false;
-                min-elements 2;
-                description "none";
-            }
-            leaf-list node {
-                type leafref {
-                    path '/tapi-common:context/tapi-topology:topology/tapi-topology:node/tapi-topology:uuid';
-                }
-                config false;
-                min-elements 2;
-                description "none";
-            }
-            container state {
-                config false;
-                uses tapi-common:admin-state-pac;
-                description "none";
-            }
-            container transfer-capacity {
-                config false;
-                uses tapi-common:capacity-pac;
-                description "none";
-            }
-            container transfer-cost {
-                config false;
-                uses transfer-cost-pac;
-                description "none";
+
+    /*************************
+    * definitions of refrences
+    *************************/
+
+    grouping topology-ref {
+        leaf topology-id {
+            type leafref {
+                path '/tapi-common:context/tapi-topology:topology/tapi-topology:uuid';
             }
-            container transfer-integrity {
-                config false;
-                uses transfer-integrity-pac;
-                description "none";
+        }
+    }
+
+    grouping link-ref {
+        uses topology-ref;
+        leaf link-id {
+            type leafref {
+                path '/tapi-common:context/tapi-topology:topology/tapi-topology:link/tapi-topology:uuid';
             }
-            container transfer-timing {
-                config false;
-                uses transfer-timing-pac;
-                description "none";
+        }
+    }
+
+    grouping node-ref {
+        uses topology-ref;
+        leaf node-id {
+            type leafref {
+                path '/tapi-common:context/tapi-topology:topology/tapi-topology:node/tapi-topology:uuid';
             }
-            container risk-parameter {
-                config false;
-                uses risk-parameter-pac;
-                description "none";
+        }
+    }
+
+    grouping owned-node-edge-point-ref {
+        uses node-ref;
+        leaf owned-node-edge-point-id {
+            type leafref {
+                path '/tapi-common:context/tapi-topology:topology/tapi-topology:node/tapi-topology:owned-node-edge-point/tapi-topology:uuid';
             }
-            container validation {
-                config false;
-                uses validation-pac;
-                description "none";
+        }
+    }
+
+    grouping node-rule-group-ref {
+        uses node-ref;
+        leaf node-rule-group-id {
+            type leafref {
+                path '/tapi-common:context/tapi-topology:topology/tapi-topology:node/tapi-topology:node-rule-group/tapi-topology:uuid';
             }
-            container lp-transition {
+        }
+    }
+
+    /***********************
+    * package object-classes
+    **********************/
+        grouping link {
+            list node-edge-point {
+                uses owned-node-edge-point-ref;
+                key 'topology-id node-id owned-node-edge-point-id';
                 config false;
-                uses layer-protocol-transition-pac;
+                min-elements 2;
                 description "none";
             }
             leaf-list layer-protocol-name {
@@ -87,11 +96,23 @@ Editor: your-name<mailto:your-email@example.com>";
             leaf direction {
                 type tapi-common:forwarding-direction;
                 config false;
-                description "The directionality of the Link. 
-                    Is applicable to simple Links where all LinkEnds are BIDIRECTIONAL (the Link will be BIDIRECTIONAL) or UNIDIRECTIONAL (the Link will be UNIDIRECTIONAL). 
+                description "The directionality of the Link.
+                    Is applicable to simple Links where all LinkEnds are BIDIRECTIONAL (the Link will be BIDIRECTIONAL) or UNIDIRECTIONAL (the Link will be UNIDIRECTIONAL).
                     Is not present in more complex cases.";
             }
+            container resilience-type {
+                uses resilience-type;
+                description "none";
+            }
             uses tapi-common:resource-spec;
+            uses tapi-common:admin-state-pac;
+            uses tapi-common:capacity-pac;
+            uses transfer-cost-pac;
+            uses transfer-integrity-pac;
+            uses transfer-timing-pac;
+            uses risk-parameter-pac;
+            uses validation-pac;
+            uses layer-protocol-transition-pac;
             description "The Link object class models effective adjacency between two or more ForwardingDomains (FD). ";
         }
         grouping node {
@@ -113,36 +134,9 @@ Editor: your-name<mailto:your-email@example.com>";
                 uses node-rule-group;
                 description "none";
             }
-            leaf encap-topology {
-                type leafref {
-                    path '/tapi-common:context/tapi-topology:topology/tapi-topology:uuid';
-                }
-                config false;
-                description "none";
-            }
-            container state {
+            container encap-topology {
+                uses topology-ref;
                 config false;
-                uses tapi-common:admin-state-pac;
-                description "none";
-            }
-            container transfer-capacity {
-                config false;
-                uses tapi-common:capacity-pac;
-                description "none";
-            }
-            container transfer-cost {
-                config false;
-                uses transfer-cost-pac;
-                description "none";
-            }
-            container transfer-integrity {
-                config false;
-                uses transfer-integrity-pac;
-                description "none";
-            }
-            container transfer-timing {
-                config false;
-                uses transfer-timing-pac;
                 description "none";
             }
             leaf-list layer-protocol-name {
@@ -152,7 +146,12 @@ Editor: your-name<mailto:your-email@example.com>";
                 description "none";
             }
             uses tapi-common:resource-spec;
-            description "The ForwardingDomain (FD) object class models the “ForwardingDomain” topological component which is used to effect forwarding of transport characteristic information and offers the potential to enable forwarding. 
+            uses tapi-common:admin-state-pac;
+            uses tapi-common:capacity-pac;
+            uses transfer-cost-pac;
+            uses transfer-integrity-pac;
+            uses transfer-timing-pac;
+            description "The ForwardingDomain (FD) object class models the “ForwardingDomain” topological component which is used to effect forwarding of transport characteristic information and offers the potential to enable forwarding.
                 At the lowest level of recursion, an FD (within a network element (NE)) represents a switch matrix (i.e., a fabric). Note that an NE can encompass multiple switch matrices (FDs). ";
         }
         grouping topology {
@@ -175,7 +174,7 @@ Editor: your-name<mailto:your-email@example.com>";
                 description "none";
             }
             uses tapi-common:resource-spec;
-            description "The ForwardingDomain (FD) object class models the “ForwardingDomain” topological component which is used to effect forwarding of transport characteristic information and offers the potential to enable forwarding. 
+            description "The ForwardingDomain (FD) object class models the “ForwardingDomain” topological component which is used to effect forwarding of transport characteristic information and offers the potential to enable forwarding.
                 At the lowest level of recursion, an FD (within a network element (NE)) represents a switch matrix (i.e., a fabric). Note that an NE can encompass multiple switch matrices (FDs). ";
         }
         grouping layer-protocol-transition-pac {
@@ -184,18 +183,16 @@ Editor: your-name<mailto:your-email@example.com>";
                 min-elements 2;
                 description "Provides the ordered structure of layer protocol transitions encapsulated in the TopologicalEntity. The ordering relates to the LinkPort role.";
             }
-            description "Relevant for a Link that is formed by abstracting one or more LTPs (in a stack) to focus on the flow and deemphasize the protocol transformation. 
-                This abstraction is relevant when considering multi-layer routing. 
+            description "Relevant for a Link that is formed by abstracting one or more LTPs (in a stack) to focus on the flow and deemphasize the protocol transformation.
+                This abstraction is relevant when considering multi-layer routing.
                 The layer protocols of the LTP and the order of their application to the signal is still relevant and need to be accounted for. This is derived from the LTP spec details.
                 This Pac provides the relevant abstractions of the LTPs and provides the necessary association to the LTPs involved.
                 Links that included details in this Pac are often referred to as Transitional Links.";
         }
         grouping node-edge-point {
-            list layer-protocol {
-                key 'local-id';
+            leaf layer-protocol-name {
+                type tapi-common:layer-protocol-name;
                 config false;
-                min-elements 1;
-                uses tapi-common:layer-protocol;
                 description "none";
             }
             leaf-list aggregated-node-edge-point {
@@ -205,16 +202,11 @@ Editor: your-name<mailto:your-email@example.com>";
                 config false;
                 description "none";
             }
-            leaf-list mapped-service-interface-point {
-                type leafref {
-                    path '/tapi-common:context/tapi-common:service-interface-point/tapi-common:uuid';
-                }
-                description "NodeEdgePoint mapped to more than ServiceInterfacePoint (slicing/virtualizing) or a ServiceInterfacePoint mapped to more than one NodeEdgePoint (load balancing/Resilience) should be considered experimental";
-            }
-            container state {
+            list mapped-service-interface-point {
+                uses tapi-common:service-interface-point-ref;
+                key 'service-interface-point-id';
                 config false;
-                uses tapi-common:admin-state-pac;
-                description "none";
+                description "NodeEdgePoint mapped to more than ServiceInterfacePoint (slicing/virtualizing) or a ServiceInterfacePoint mapped to more than one NodeEdgePoint (load balancing/Resilience) should be considered experimental";
             }
             leaf link-port-direction {
                 type tapi-common:port-direction;
@@ -227,7 +219,10 @@ Editor: your-name<mailto:your-email@example.com>";
                 description "Each LinkEnd of the Link has a role (e.g., symmetric, hub, spoke, leaf, root)  in the context of the Link with respect to the Link function. ";
             }
             uses tapi-common:resource-spec;
-            description "The LogicalTerminationPoint (LTP) object class encapsulates the termination and adaptation functions of one or more transport layers. 
+            uses tapi-common:admin-state-pac;
+            uses tapi-common:termination-pac;
+            uses tapi-common:capacity-pac;
+            description "The LogicalTerminationPoint (LTP) object class encapsulates the termination and adaptation functions of one or more transport layers.
                 The structure of LTP supports all transport protocols including circuit and packet forms.";
         }
         grouping risk-parameter-pac {
@@ -238,7 +233,7 @@ Editor: your-name<mailto:your-email@example.com>";
                 uses risk-characteristic;
                 description "A list of risk characteristics for consideration in an analysis of shared risk. Each element of the list represents a specific risk consideration.";
             }
-            description "The risk characteristics of a TopologicalEntity come directly from the underlying physical realization. 
+            description "The risk characteristics of a TopologicalEntity come directly from the underlying physical realization.
                 The risk characteristics propagate from the physical realization to the client and from the server layer to the client layer, this propagation may be modified by protection.
                 A TopologicalEntity may suffer degradation or failure as a result of a problem in a part of the underlying realization.
                 The realization can be partitioned into segments which have some relevant common failure modes.
@@ -253,22 +248,22 @@ Editor: your-name<mailto:your-email@example.com>";
         }
         grouping transfer-cost-pac {
             list cost-characteristic {
-                key 'cost-name cost-value cost-algorithm';
+                key 'cost-name';
                 config false;
                 min-elements 1;
                 uses cost-characteristic;
                 description "The list of costs where each cost relates to some aspect of the TopologicalEntity.";
             }
-            description "The cost characteristics of a TopologicalEntity not necessarily correlated to the cost of the underlying physical realization. 
+            description "The cost characteristics of a TopologicalEntity not necessarily correlated to the cost of the underlying physical realization.
                 They may be quite specific to the individual TopologicalEntity e.g. opportunity cost. Relates to layer capacity
-                There may be many perspectives from which cost may be considered  for a particular TopologicalEntity and hence many specific costs and potentially cost algorithms. 
+                There may be many perspectives from which cost may be considered  for a particular TopologicalEntity and hence many specific costs and potentially cost algorithms.
                 Using an entity will incur a cost. ";
         }
         grouping transfer-integrity-pac {
             leaf error-characteristic {
                 type string;
                 config false;
-                description "Describes the degree to which the signal propagated can be errored. 
+                description "Describes the degree to which the signal propagated can be errored.
                     Applies to TDM systems as the errored signal will be propagated and not packet as errored packets will be discarded.";
             }
             leaf loss-characteristic {
@@ -280,7 +275,7 @@ Editor: your-name<mailto:your-email@example.com>";
             leaf repeat-delivery-characteristic {
                 type string;
                 config false;
-                description "Primarily applies to packet systems where a packet may be delivered more than once (in fault recovery for example). 
+                description "Primarily applies to packet systems where a packet may be delivered more than once (in fault recovery for example).
                     It can also apply to TDM where several frames may be received twice due to switching in a system with a large differential propagation delay.";
             }
             leaf delivery-order-characteristic {
@@ -305,7 +300,7 @@ Editor: your-name<mailto:your-email@example.com>";
         }
         grouping transfer-timing-pac {
             list latency-characteristic {
-                key 'traffic-property-name traffic-property-queing-latency';
+                key 'traffic-property-name';
                 config false;
                 min-elements 1;
                 uses latency-characteristic;
@@ -315,7 +310,7 @@ Editor: your-name<mailto:your-email@example.com>";
         }
         grouping validation-pac {
             list validation-mechanism {
-                key 'validation-mechanism layer-protocol-adjacency-validated validation-robustness';
+                key 'validation-mechanism';
                 config false;
                 min-elements 1;
                 uses validation-mechanism;
@@ -355,30 +350,17 @@ Editor: your-name<mailto:your-email@example.com>";
                 uses rule;
                 description "none";
             }
-            leaf-list associated-node-rule-group {
-                type leafref {
-                    path '/tapi-common:context/tapi-topology:topology/tapi-topology:node/tapi-topology:node-rule-group/tapi-topology:uuid';
-                }
+            list associated-node-rule-group {
+                uses node-rule-group-ref;
+                key 'topology-id node-id node-rule-group-id';
                 min-elements 2;
                 description "none";
             }
-            container transfer-capacity {
-                uses tapi-common:capacity-pac;
-                description "none";
-            }
-            container transfer-cost {
-                uses transfer-cost-pac;
-                description "none";
-            }
-            container transfer-timing {
-                uses transfer-timing-pac;
-                description "none";
-            }
-            container risk-parameter {
-                uses risk-parameter-pac;
-                description "none";
-            }
             uses tapi-common:resource-spec;
+            uses tapi-common:capacity-pac;
+            uses transfer-cost-pac;
+            uses transfer-timing-pac;
+            uses risk-parameter-pac;
             description "none";
         }
         grouping node-rule-group {
@@ -395,10 +377,9 @@ Editor: your-name<mailto:your-email@example.com>";
                 min-elements 1;
                 description "none";
             }
-            leaf-list node-rule-group {
-                type leafref {
-                    path '/tapi-common:context/tapi-topology:topology/tapi-topology:node/tapi-topology:node-rule-group/tapi-topology:uuid';
-                }
+            list node-rule-group {
+                uses node-rule-group-ref;
+                key 'topology-id node-id node-rule-group-id';
                 description "none";
             }
             list inter-rule-group {
@@ -406,23 +387,11 @@ Editor: your-name<mailto:your-email@example.com>";
                 uses inter-rule-group;
                 description "none";
             }
-            container transfer-capacity {
-                uses tapi-common:capacity-pac;
-                description "none";
-            }
-            container transfer-cost {
-                uses transfer-cost-pac;
-                description "none";
-            }
-            container transfer-timing {
-                uses transfer-timing-pac;
-                description "none";
-            }
-            container risk-parameter {
-                uses risk-parameter-pac;
-                description "none";
-            }
             uses tapi-common:resource-spec;
+            uses tapi-common:capacity-pac;
+            uses transfer-cost-pac;
+            uses transfer-timing-pac;
+            uses risk-parameter-pac;
             description "none";
         }
         grouping rule {
@@ -461,11 +430,19 @@ Editor: your-name<mailto:your-email@example.com>";
             description "The information for a particular cost characteristic.";
         }
         grouping latency-characteristic {
+            leaf traffic-property-name {
+                type string;
+                description "The identifier of the specific traffic property to which the queuing latency applies.";
+            }
             leaf fixed-latency-characteristic {
                 type string;
                 config false;
                 description "A TopologicalEntity suffers delay caused by the realization of the servers (e.g. distance related; FEC encoding etc.) along with some client specific processing. This is the total average latency effect of the TopologicalEntity";
             }
+            leaf queing-latency-characteristic {
+                type string;
+                description "The specific queuing latency for the traffic property.";
+            }
             leaf jitter-characteristic {
                 type string;
                 config false;
@@ -478,14 +455,6 @@ Editor: your-name<mailto:your-email@example.com>";
                 description "Low frequency deviation from true periodicity of a signal and therefore a small low rate of change of transfer latency.
                     Applies to TDM systems (and not packet).";
             }
-            leaf traffic-property-name {
-                type string;
-                description "The identifier of the specific traffic property to which the queuing latency applies.";
-            }
-            leaf traffic-property-queing-latency {
-                type string;
-                description "The specific queuing latency for the traffic property.";
-            }
             description "Provides information on latency characteristic for a particular stated trafficProperty.";
         }
         grouping risk-characteristic {
@@ -557,6 +526,57 @@ Editor: your-name<mailto:your-email@example.com>";
             }
             description "none";
         }
+        grouping resilience-type {
+            leaf restoration-policy {
+                type restoration-policy;
+                description "none";
+            }
+            leaf protection-type {
+                type protection-type;
+                description "none";
+            }
+            description "none";
+        }
+        typedef restoration-policy {
+            type enumeration {
+                enum PER_DOMAIN_RESTORATION {
+                    description "none";
+                }
+                enum END_TO_END_RESTORATION {
+                    description "none";
+                }
+                enum NA {
+                    description "none";
+                }
+            }
+            description "none";
+        }
+        typedef protection-type {
+            type enumeration {
+                enum NO_PROTECTON {
+                    description "none";
+                }
+                enum ONE_PLUS_ONE_PROTECTION {
+                    description "none";
+                }
+                enum ONE_PLUS_ONE_PROTECTION_WITH_DYNAMIC_RESTORATION {
+                    description "none";
+                }
+                enum PERMANENT_ONE_PLUS_ONE_PROTECTION {
+                    description "none";
+                }
+                enum ONE_FOR_ONE_PROTECTION {
+                    description "none";
+                }
+                enum DYNAMIC_RESTORATION {
+                    description "none";
+                }
+                enum PRE_COMPUTED_RESTORATION {
+                    description "none";
+                }
+            }
+            description "none";
+        }
 
     /***********************
     * package interfaces