Always hold VnfDf InstantiationLevels type in JSON even if it's empty

Before Change 747678, it had been so and it was "null" rather than "{}".
747678 did not have any intention such that as per SOL011 v3.4.1 7.1.8
we shall make it mandatory, even though it's quite reasonable to think
of it as optional in accordance with SOL001 v2.7.1(~v3.4.1) 6.11.2 and
TOSCA Simple Profile in YAML v1.2(~v1.3). It was just a bug so let's
partially revert it.

Related-Bug: #1886213
Change-Id: I69ffa26227b49b4ad59b71f5b54fa61a0f0b5107
This commit is contained in:
Koichiro Den 2020-10-29 12:49:35 +09:00
parent 25f93312c1
commit 32b51d7a96
1 changed files with 2 additions and 3 deletions

View File

@ -387,7 +387,6 @@ class Conductor(manager.Manager):
deploy_flavour.package_uuid = package_uuid
deploy_flavour.flavour_id = flavour['flavour_id']
deploy_flavour.flavour_description = flavour['flavour_description']
if flavour.get('instantiation_levels'):
deploy_flavour.instantiation_levels = \
flavour.get('instantiation_levels')
deploy_flavour.create()