/*
*
- * Copyright 2016 RIFT.IO Inc
+ * Copyright 2016-2017 RIFT.IO Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
prefix "manotypes";
}
+ import rw-project {
+ prefix "rw-project";
+ }
+
+ revision 2017-02-08 {
+ description
+ "Update model to support projects.";
+ }
+
revision 2014-10-27 {
description
"Initial revision. This YANG file defines
}
}
- grouping nsd-descriptor {
+ grouping nsd-descriptor-common {
leaf id {
description "Identifier for the NSD.";
type string;
}
}
- /* Still having issues modelling this,
- see the comments under vnfd-connection-point-ref
- */
- list vld {
- description
- "List of Virtual Link Descriptors.";
-
- key "id";
-
- leaf id {
- description
- "Identifier for the VLD.";
- type string;
- }
-
- leaf name {
- description
- "Virtual Link Descriptor (VLD) name.";
- type string;
- }
-
- leaf short-name {
- description
- "Short name for VLD for UI";
- type string;
- }
-
- leaf vendor {
- description "Provider of the VLD.";
- type string;
- }
-
- leaf description {
- description "Description of the VLD.";
- type string;
- }
-
- leaf version {
- description "Version of the VLD";
- type string;
- }
-
- leaf type {
- type manotypes:virtual-link-type;
- }
-
- leaf root-bandwidth {
- description
- "For ELAN this is the aggregate bandwidth.";
- type uint64;
- }
-
- leaf leaf-bandwidth {
- description
- "For ELAN this is the bandwidth of branches.";
- type uint64;
- }
-
- list vnfd-connection-point-ref {
- description
- "A list of references to connection points.";
- key "member-vnf-index-ref vnfd-connection-point-ref";
-
- leaf member-vnf-index-ref {
- description "Reference to member-vnf within constituent-vnfds";
- type leafref {
- path "../../../constituent-vnfd/member-vnf-index";
- }
- }
-
- 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 leafref {
- path "../../../constituent-vnfd" +
- "[member-vnf-index = current()/../member-vnf-index-ref]" +
- "/vnfd-id-ref";
- }
- }
-
- 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";
-
- case vim-network-ref {
- leaf vim-network-name {
- description
- "Name of network in VIM account. This is used to indicate
- pre-provisioned network name in cloud account.";
- type string;
- }
- }
-
- case vim-network-profile {
- leaf ip-profile-ref {
- description "Named reference to IP-profile object";
- type string;
- }
- }
-
- }
- }
-
- list constituent-vnfd {
- description
- "List of VNFDs that are part of this
- network service.";
-
- key "member-vnf-index";
-
- leaf member-vnf-index {
- description
- "Identifier/index for the VNFD. This separate id
- is required to ensure that multiple VNFs can be
- part of single NS";
- type uint64;
- }
-
- leaf vnfd-id-ref {
- description
- "Identifier for the VNFD.";
- type leafref {
- path "/vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
- }
- }
-
- leaf start-by-default {
- description
- "VNFD is started as part of the NS instantiation";
- type boolean;
- default true;
- }
- }
-
list scaling-group-descriptor {
description
"scaling group descriptor within this network service.
leaf scale-in-operation-type {
description
- "Operation to be applied to check between scaling criterias to
+ "Operation to be applied to check between scaling criterias to
check if the scale in threshold condition has been met.
Defaults to AND";
type scaling-criteria-operation;
leaf scale-out-operation-type {
description
- "Operation to be applied to check between scaling criterias to
+ "Operation to be applied to check between scaling criterias to
check if the scale out threshold condition has been met.
Defauls to OR";
type scaling-criteria-operation;
}
leaf ns-monitoring-param-ref {
- description
+ description
"Reference to the NS level monitoring parameter
that is aggregated";
type leafref {
}
}
- list placement-groups {
- description "List of placement groups at NS level";
-
- key "name";
- uses manotypes:placement-group-info;
-
- list member-vnfd {
- description
- "List of VNFDs that are part of this placement group";
-
- key "member-vnf-index-ref";
-
- leaf member-vnf-index-ref {
- description "member VNF index of this member VNF";
- type leafref {
- path "../../../constituent-vnfd/member-vnf-index";
- }
- }
-
- leaf vnfd-id-ref {
- description
- "Identifier for the VNFD.";
- type leafref {
- path "../../../constituent-vnfd" +
- "[member-vnf-index = current()/../member-vnf-index-ref]" +
- "/vnfd-id-ref";
- }
- }
- }
- }
-
- uses manotypes:ip-profile-list;
-
- list vnf-dependency {
- description
- "List of VNF dependencies.";
- key vnf-source-ref;
- leaf vnf-source-ref {
- type leafref {
- path "../../constituent-vnfd/vnfd-id-ref";
- }
- }
- leaf vnf-depends-on-ref {
- description
- "Reference to VNF that sorce VNF depends.";
- type leafref {
- path "../../constituent-vnfd/vnfd-id-ref";
- }
- }
- }
list vnffgd {
description
list rsp {
description
- "List of Rendered Service Paths (RSP).";
+ "List of Rendered Service Paths (RSP).";
key "id";
leaf id {
description
- "Identifier for the RSP.";
+ "Identifier for the RSP.";
type string;
}
leaf name {
description
- "RSP name.";
+ "RSP name.";
type string;
}
list vnfd-connection-point-ref {
description
- "A list of references to connection points.";
+ "A list of references to connection points.";
key "member-vnf-index-ref";
leaf member-vnf-index-ref {
leaf order {
type uint8;
description
- "A number that denotes the order of a VNF in a chain";
+ "A number that denotes the order of a VNF in a chain";
}
- leaf vnfd-id-ref {
- description
- "A reference to a vnfd. This is a
+ 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]
}
}
- leaf vnfd-connection-point-ref {
- description
- "A reference to a connection point name
+ 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]
to leafref, whose target is in a different module.
Once that is resovled this will switched to use
leafref";
- type leafref {
- path "/vnfd:vnfd-catalog/vnfd:vnfd" +
- "[vnfd:id = current()/../vnfd-id-ref]/" +
- "vnfd:connection-point/vnfd:name";
- }
+ // TODO: Keeping as string as this needs to be
+ // diffenent lvel based of if it is nsd-catalog or
+ // in nsr.
+ // type leafref {
+ // path "../../../../../../vnfd:vnfd-catalog/vnfd:vnfd" +
+ // "[vnfd:id = current()/../vnfd-id-ref]/" +
+ // "vnfd:connection-point/vnfd:name";
+ // }
+ type string;
}
}
} //rsp
to leafref, whose target is in a different module.
Once that is resovled this will switched to use
leafref";
- type leafref {
- path "/vnfd:vnfd-catalog/vnfd:vnfd" +
- "[vnfd:id = current()/../vnfd-id-ref]/" +
- "vnfd:connection-point/vnfd:name";
- }
+ // TODO: Keeping as string as this needs to be
+ // diffenent lvel based of if it is nsd-catalog or
+ // in nsr.
+ // type leafref {
+ // path "../../../../../vnfd:vnfd-catalog/vnfd:vnfd" +
+ // "[vnfd:id = current()/../vnfd-id-ref]/" +
+ // "vnfd:connection-point/vnfd:name";
+ // }
+ type string;
}
list match-attributes {
} // classifier
} // vnffgd
- list monitoring-param {
- description
- "List of monitoring parameters from VNF's that should be
- propogated up into NSR";
- key "id";
-
- leaf id {
- type string;
- }
-
- leaf name {
- type string;
- }
-
- uses manotypes:monitoring-param-value;
- uses manotypes:monitoring-param-ui-data;
- uses manotypes:monitoring-param-aggregation;
-
- list vnfd-monitoring-param {
- description "A list of VNFD monitoring params";
- key "member-vnf-index-ref vnfd-monitoring-param-ref";
-
- 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 resolved this will switched to use
- leafref";
+ uses manotypes:ip-profile-list;
- type leafref {
- path "../../../constituent-vnfd" +
- "[member-vnf-index = current()/../member-vnf-index-ref]" +
- "/vnfd-id-ref";
- }
- }
+ uses manotypes:ns-service-primitive;
- leaf vnfd-monitoring-param-ref {
- description "A reference to the VNFD monitoring param";
- type leafref {
- path "/vnfd:vnfd-catalog/vnfd:vnfd"
- + "[vnfd:id = current()/../vnfd-id-ref]"
- + "/vnfd:monitoring-param/vnfd:id";
- }
- }
+ list initial-config-primitive {
+ rwpb:msg-new NsdInitialConfigPrimitive;
+ description
+ "Initial set of configuration primitives for NSD.";
+ key "seq";
- leaf member-vnf-index-ref {
- description
- "Mandatory reference to member-vnf within constituent-vnfds";
- type leafref {
- path "../../../constituent-vnfd/member-vnf-index";
- }
- }
- }
+ uses manotypes:initial-config;
}
uses manotypes:input-parameter-xpath;
}
}
- uses manotypes:ns-service-primitive;
-
- list initial-config-primitive {
- rwpb:msg-new NsdInitialConfigPrimitive;
- description
- "Initial set of configuration primitives for NSD.";
- key "seq";
-
- uses manotypes:initial-config;
- }
-
list key-pair {
key "name";
description "Used to configure the list of public keys to be injected as part
}
}
-
- container nsd-catalog {
-
- list nsd {
+ grouping nsd-vld-common {
+ /* Still having issues modelling this,
+ see the comments under vnfd-connection-point-ref
+ */
+ description
+ "List of Virtual Link Descriptors.";
+
+ leaf id {
+ description
+ "Identifier for the VLD.";
+ type string;
+ }
+
+ leaf name {
+ description
+ "Virtual Link Descriptor (VLD) name.";
+ type string;
+ }
+
+ leaf short-name {
+ description
+ "Short name for VLD for UI";
+ type string;
+ }
+
+ leaf vendor {
+ description "Provider of the VLD.";
+ type string;
+ }
+
+ leaf description {
+ description "Description of the VLD.";
+ type string;
+ }
+
+ leaf version {
+ description "Version of the VLD";
+ type string;
+ }
+
+ leaf type {
+ type manotypes:virtual-link-type;
+ }
+
+ leaf root-bandwidth {
+ description
+ "For ELAN this is the aggregate bandwidth.";
+ type uint64;
+ }
+
+ leaf leaf-bandwidth {
+ description
+ "For ELAN this is the bandwidth of branches.";
+ type uint64;
+ }
+
+ // 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";
+
+ case vim-network-ref {
+ leaf vim-network-name {
+ description
+ "Name of network in VIM account. This is used to indicate
+ pre-provisioned network name in cloud account.";
+ type string;
+ }
+ }
+
+ case vim-network-profile {
+ leaf ip-profile-ref {
+ description "Named reference to IP-profile object";
+ type string;
+ }
+ }
+
+ }
+ }
+
+ grouping nsd-vld {
+ list vld {
+
+ key "id";
+
+ uses nsd-vld-common;
+
+ list vnfd-connection-point-ref {
+ description
+ "A list of references to connection points.";
+ key "member-vnf-index-ref vnfd-connection-point-ref";
+
+ leaf member-vnf-index-ref {
+ description "Reference to member-vnf within constituent-vnfds";
+ type leafref {
+ path "../../../constituent-vnfd/member-vnf-index";
+ }
+ }
+
+ 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";
+ }
+ }
+ }
+ }
+ }
+
+ grouping nsr-nsd-vld {
+ list vld {
+
+ key "id";
+
+ uses nsd-vld-common;
+
+ list vnfd-connection-point-ref {
+ description
+ "A list of references to connection points.";
+ key "member-vnf-index-ref vnfd-connection-point-ref";
+
+ leaf member-vnf-index-ref {
+ description "Reference to member-vnf within constituent-vnfds";
+ type leafref {
+ path "../../../constituent-vnfd/member-vnf-index";
+ }
+ }
+
+ 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";
+ }
+ }
+ }
+ }
+ }
+
+ grouping nsd-constituent-vnfd {
+ list constituent-vnfd {
+ description
+ "List of VNFDs that are part of this
+ network service.";
+
+ key "member-vnf-index";
+
+ leaf member-vnf-index {
+ description
+ "Identifier/index for the VNFD. This separate id
+ is required to ensure that multiple VNFs can be
+ part of single NS";
+ type uint64;
+ }
+
+ leaf vnfd-id-ref {
+ description
+ "Identifier for the VNFD.";
+ type leafref {
+ path "../../../../vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
+ }
+ }
+
+ leaf start-by-default {
+ description
+ "VNFD is started as part of the NS instantiation";
+ type boolean;
+ default true;
+ }
+ }
+ }
+
+ grouping nsr-nsd-constituent-vnfd {
+ list constituent-vnfd {
+ description
+ "List of VNFDs that are part of this
+ network service.";
+
+ key "member-vnf-index";
+
+ leaf member-vnf-index {
+ description
+ "Identifier/index for the VNFD. This separate id
+ is required to ensure that multiple VNFs can be
+ part of single NS";
+ type uint64;
+ }
+
+ leaf vnfd-id-ref {
+ description
+ "Identifier for the VNFD.";
+ type leafref {
+ path "../../../../../vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
+ }
+ }
+
+ leaf start-by-default {
+ description
+ "VNFD is started as part of the NS instantiation";
+ type boolean;
+ default true;
+ }
+ }
+ }
+
+ grouping nsd-placement-groups {
+ list placement-groups {
+ description "List of placement groups at NS level";
+
+ key "name";
+ uses manotypes:placement-group-info;
+
+ list member-vnfd {
+ description
+ "List of VNFDs that are part of this placement group";
+
+ key "member-vnf-index-ref";
+
+ leaf member-vnf-index-ref {
+ description "member VNF index of this member VNF";
+ type leafref {
+ path "../../../constituent-vnfd/member-vnf-index";
+ }
+ }
+
+ leaf vnfd-id-ref {
+ description
+ "Identifier for the VNFD.";
+ type leafref {
+ path "../../../../../vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
+ }
+ }
+ }
+ }
+ }
+
+ grouping nsr-nsd-placement-groups {
+ list placement-groups {
+ description "List of placement groups at NS level";
+
+ key "name";
+ uses manotypes:placement-group-info;
+
+ list member-vnfd {
+ description
+ "List of VNFDs that are part of this placement group";
+
+ key "member-vnf-index-ref";
+
+ leaf member-vnf-index-ref {
+ description "member VNF index of this member VNF";
+ type leafref {
+ path "../../../constituent-vnfd/member-vnf-index";
+ }
+ }
+
+ leaf vnfd-id-ref {
+ description
+ "Identifier for the VNFD.";
+ type leafref {
+ path "../../../../../../vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
+ }
+ }
+ }
+ }
+ }
+
+ grouping nsd-vnf-dependency {
+ list vnf-dependency {
+ description
+ "List of VNF dependencies.";
+ key vnf-source-ref;
+ leaf vnf-source-ref {
+ type leafref {
+ path "../../../../vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
+ }
+ }
+ leaf vnf-depends-on-ref {
+ description
+ "Reference to VNF that sorce VNF depends.";
+ type leafref {
+ path "../../../../vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
+ }
+ }
+ }
+ }
+
+ grouping nsr-nsd-vnf-dependency {
+ list vnf-dependency {
+ description
+ "List of VNF dependencies.";
+ key vnf-source-ref;
+ leaf vnf-source-ref {
+ type leafref {
+ path "../../../../../vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
+ }
+ }
+ leaf vnf-depends-on-ref {
+ description
+ "Reference to VNF that sorce VNF depends.";
+ type leafref {
+ path "../../../../../vnfd:vnfd-catalog/vnfd:vnfd/vnfd:id";
+ }
+ }
+ }
+ }
+
+ grouping monitoring-param-common {
+ // list monitoring-param {
+ description
+ "List of monitoring parameters from VNF's that should be
+ propogated up into NSR";
+ leaf id {
+ type string;
+ }
+
+ leaf name {
+ type string;
+ }
+
+ uses manotypes:monitoring-param-value;
+ uses manotypes:monitoring-param-ui-data;
+ uses manotypes:monitoring-param-aggregation;
+ }
+
+ grouping nsd-monitoring-param {
+
+ list monitoring-param {
key "id";
- uses nsd-descriptor;
+ uses monitoring-param-common;
+
+ list vnfd-monitoring-param {
+ description "A list of VNFD monitoring params";
+ key "vnfd-id-ref vnfd-monitoring-param-ref";
+
+ 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 resolved this will switched to use
+ leafref";
+
+ type yang:uuid;
+ }
+
+ leaf vnfd-monitoring-param-ref {
+ description "A reference to the VNFD monitoring param";
+ type leafref {
+ path "../../../../../vnfd:vnfd-catalog/vnfd:vnfd"
+ + "[vnfd:id = current()/../vnfd-id-ref]"
+ + "/vnfd:monitoring-param/vnfd:id";
+ }
+ }
+
+ leaf-list member-vnf-index-ref {
+ description
+ "Optional reference to member-vnf within constituent-vnfds";
+ type uint64;
+ }
+ }
+ }
+ }
+
+ grouping nsr-nsd-monitoring-param {
+ list monitoring-param {
+ key "id";
+
+ uses monitoring-param-common;
+
+ list vnfd-monitoring-param {
+ description "A list of VNFD monitoring params";
+ key "vnfd-id-ref vnfd-monitoring-param-ref";
+
+ 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 resolved this will switched to use
+ leafref";
+
+ type yang:uuid;
+ }
+
+ leaf vnfd-monitoring-param-ref {
+ description "A reference to the VNFD monitoring param";
+ type leafref {
+ path "../../../../../../vnfd:vnfd-catalog/vnfd:vnfd"
+ + "[vnfd:id = current()/../vnfd-id-ref]"
+ + "/vnfd:monitoring-param/vnfd:id";
+ }
+ }
+
+ leaf-list member-vnf-index-ref {
+ description
+ "Optional reference to member-vnf within constituent-vnfds";
+ type uint64;
+ }
+ }
}
}
+
+ augment "/rw-project:project" {
+ container nsd-catalog {
+
+ list nsd {
+ key "id";
+
+ uses nsd-descriptor-common;
+
+ uses nsd-vld;
+
+ uses nsd-constituent-vnfd;
+
+ uses nsd-placement-groups;
+
+ uses nsd-vnf-dependency;
+
+ uses nsd-monitoring-param;
+ }
+ }
+ }
}