From: garciadeblas Date: Fri, 19 Oct 2018 12:31:56 +0000 (+0200) Subject: Added name to nsi and nst as mandatory; removed wrong nst params; netslice instantiat... X-Git-Tag: v5.0.0~3^2 X-Git-Url: https://osm.etsi.org/gitweb/?p=osm%2FIM.git;a=commitdiff_plain;h=ff4b926e0a81c4010acc2684f4c0e97e565cd57a;ds=sidebyside Added name to nsi and nst as mandatory; removed wrong nst params; netslice instantiation parameters Change-Id: Idf2e203ca2dc95e4ad370c532cc6a014eb641da8 Signed-off-by: garciadeblas --- diff --git a/models/yang/instantiation-parameters.yang b/models/yang/instantiation-parameters.yang index 810b959..dbf38b7 100644 --- a/models/yang/instantiation-parameters.yang +++ b/models/yang/instantiation-parameters.yang @@ -10,10 +10,6 @@ module instantiation-parameters { namespace "urn:ietf:params:xml:ns:yang:nfvo:instantiation-parameters"; prefix "instantiation-parameters"; - import rw-project { - prefix "rw-project"; - } - import nsd { prefix "nsd"; } @@ -22,10 +18,6 @@ module instantiation-parameters { prefix "vnfd"; } - import nsr { - prefix "nsr"; - } - import ietf-inet-types { prefix "inet"; } @@ -39,20 +31,33 @@ module instantiation-parameters { description "Initial version"; } - grouping ns_instantiate { - leaf nsName { + grouping netslice_params { + leaf vimAccountId { mandatory true; type string; } - leaf nsDescription { + leaf ssh_keys { type string; } - leaf nsdId { + list netslice-subnet { + key "id"; + uses netslice_subnet_params; + } + list netslice-vld { + key "name"; + uses vld_params; + } + } + + grouping netslice_subnet_params { + leaf id { mandatory true; - type leafref { - path "/nsd:nsd-catalog/nsd:nsd/nsd:id"; - } + type string; } + uses ns_params; + } + + grouping ns_params { leaf vimAccountId { mandatory true; type string; @@ -60,23 +65,17 @@ module instantiation-parameters { leaf ssh_keys { type string; } - leaf nsr_id { - config false; - type leafref { - path "/rw-project:project/nsr:ns-instance-opdata/nsr:nsr/nsr:ns-instance-config-ref"; - } - } list vnf { key "member-vnf-index"; - uses vnf; + uses vnf_params; } list vld { key "name"; - uses vld; + uses vld_params; } } - grouping vnf { + grouping vnf_params { leaf member-vnf-index{ mandatory true; type string; @@ -86,15 +85,15 @@ module instantiation-parameters { } list vdu { key "id"; - uses ns_instantiate_vdu; + uses vdu_params; } list internal-vld { key "name"; - uses ns-instantiate-internal-vld; + uses internal_vld_params; } } - grouping vld { + grouping vld_params { leaf name { type string; } @@ -123,7 +122,7 @@ module instantiation-parameters { } } - grouping ns_instantiate_vdu { + grouping vdu_params { leaf id { mandatory true; type string; @@ -157,7 +156,7 @@ module instantiation-parameters { } } - grouping ns-instantiate-internal-vld { + grouping internal_vld_params { leaf name { mandatory true; type string; @@ -210,4 +209,4 @@ module instantiation-parameters { } } -} \ No newline at end of file +} diff --git a/models/yang/nsi.yang b/models/yang/nsi.yang index 32087d3..b6184e1 100644 --- a/models/yang/nsi.yang +++ b/models/yang/nsi.yang @@ -30,6 +30,10 @@ module nsi { prefix "instantiation-parameters"; } + import ietf-yang-types { + prefix "yang"; + } + //revision history revision 2018-09-28 { description "Initial version"; @@ -37,23 +41,35 @@ module nsi { grouping nsi { leaf id { + description "Identifier for the NSI."; + type yang:uuid; + } + + leaf name { + description "NSI name."; + type string; + mandatory true; + } + + leaf short-name { + description "NSI short name."; type string; } + + leaf description { + description "NSI description."; + type string; + } + leaf nst-ref { type leafref { path "/nst:nst/nst:id"; } + mandatory true; } container instantiation-parameters { - list netslice-subnet { - key "nsdId"; - uses instantiation-parameters:ns_instantiate; - } - list netslice-vld { - key "name"; - uses instantiation-parameters:vld; - } + uses instantiation-parameters:netslice_params; } container network-slice-template { @@ -87,6 +103,7 @@ module nsi { list nsi{ key "id"; + unique "name"; uses nsi; } diff --git a/models/yang/nst.yang b/models/yang/nst.yang index b501dae..85e2917 100644 --- a/models/yang/nst.yang +++ b/models/yang/nst.yang @@ -140,41 +140,20 @@ module nst { grouping netslice-subnet { leaf id { - description "Identifier for the netslice-subnet."; + description "Identifier or name for the netslice-subnet in NST scope."; mandatory true; type string { length 1..63; } } - leaf name { - description "netslice-subnet name."; - mandatory true; - type string; - } - leaf short-name { - description "Short name to appear as label in the UI"; - mandatory true; - type string; - } - leaf vendor { - description "Vendor of the NSD."; - mandatory true; + leaf description { + description "Description of the NSD."; type string; } leaf is-shared-nss { description "NSS is shared between NS"; - mandatory true; type boolean; - } - leaf description { - description "Description of the NSD."; - mandatory true; - type string; - } - leaf version { - description "Version of the NSD"; - mandatory true; - type string; + default false; } leaf nsd-ref { description "Reference to catalog NSD"; @@ -184,7 +163,7 @@ module nst { } } container instantiation-parameters { - uses instantiation-parameters:ns_instantiate; + uses instantiation-parameters:ns_params; } } @@ -297,6 +276,7 @@ module nst { leaf name { type string; + mandatory true; } container SNSSAI-identifier { @@ -317,7 +297,7 @@ module nst { key "id"; uses nsvld; } - list netslicefgd{ + list netslicefgd { key "id"; uses netslicefgd; }