NOTICKET: Fix onboard_pkg utility for new package management semantics
[osm/SO.git] / models / plugins / yang / nsd.yang
index ac0987c..3d08627 100644 (file)
@@ -124,38 +124,6 @@ module nsd
     }
   }
 
-  grouping ns-initial-config-primitive {
-    leaf seq {
-      description
-          "Sequence number for the configuration primitive.";
-      type uint64;
-    }
-
-    leaf name {
-      description
-          "Name of the configuration primitive.";
-      type string;
-      mandatory "true";
-    }
-
-    leaf user-defined-script {
-      description
-          "A user defined script.";
-      type string;
-    }
-
-    list parameter {
-      key "name";
-      leaf name {
-        type string;
-      }
-
-      leaf value {
-        type string;
-      }
-    }
-  }
-
   grouping nsd-descriptor {
     leaf id {
       description "Identifier for the NSD.";
@@ -283,7 +251,7 @@ module nsd
       list vnfd-connection-point-ref {
         description
             "A list of references to connection points.";
-        key "member-vnf-index-ref";
+        key "member-vnf-index-ref vnfd-connection-point-ref";
 
         leaf member-vnf-index-ref {
           description "Reference to member-vnf within constituent-vnfds";
@@ -292,40 +260,40 @@ module nsd
           }
         }
 
-         leaf vnfd-id-ref {
-           description
-               "A reference to a vnfd. This is a
-                leafref to path:
-                    ../../nsd:constituent-vnfd
-                    + [nsd:id = current()/../nsd:id-ref]
-                    + /nsd:vnfd-id-ref
-                NOTE: An issue with confd is preventing the
-                use of xpath. Seems to be an issue with leafref
-                to leafref, whose target is in a different module.
-                Once that is resovled this will switched to use
-                leafref";
-           type string;
-         }
-
-         leaf vnfd-connection-point-ref {
-           description
-               "A reference to a connection point name
-                in a vnfd. This is a leafref to path:
-                    /vnfd:vnfd-catalog/vnfd:vnfd
-                    + [vnfd:id = current()/../nsd:vnfd-id-ref]
-                    + /vnfd:connection-point/vnfd:name
-                NOTE: An issue with confd is preventing the
-                use of xpath. Seems to be an issue with leafref
-                to leafref, whose target is in a different module.
-                Once that is resovled this will switched to use
-                leafref";
-            type string;
+        leaf vnfd-id-ref {
+          description
+              "A reference to a vnfd. This is a
+               leafref to path:
+                   ../../nsd:constituent-vnfd
+                   + [nsd:id = current()/../nsd:id-ref]
+                   + /nsd:vnfd-id-ref
+               NOTE: An issue with confd is preventing the
+               use of xpath. Seems to be an issue with leafref
+               to leafref, whose target is in a different module.
+               Once that is resovled this will switched to use
+               leafref";
+          type string;
+        }
+
+        leaf vnfd-connection-point-ref {
+          description "A reference to a connection point name";
+          type leafref {
+            path "/vnfd:vnfd-catalog/vnfd:vnfd" +
+                 "[vnfd:id = current()/../vnfd-id-ref]/" +
+                 "vnfd:connection-point/vnfd:name";
+          }
         }
       }
 
       // replicate for pnfd container here
       uses manotypes:provider-network;
 
+      leaf mgmt-network {
+         description "Flag indicating whether this network is a VIM management network"; 
+         type boolean;
+         default false;
+      }
+
       choice init-params {
         description "Extra parameters for VLD instantiation";
 
@@ -337,12 +305,14 @@ module nsd
             type string;
           }
         }
+
         case vim-network-profile {
           leaf ip-profile-ref {
             description "Named reference to IP-profile object";
             type string;
           } 
-        }   
+        }
+
       }
     }
 
@@ -900,7 +870,7 @@ module nsd
         "Initial set of configuration primitives for NSD.";
       key "seq";
 
-      uses ns-initial-config-primitive;
+      uses manotypes:initial-config;
     }
 
     list key-pair {