for vim in vims:
extra={'datacenter_tenant_id': vim.get('datacenter_tenant_id'),
'datacenter_id': vim.get('datacenter_id'),
- 'vim_type': vim.get('type')}
+ '_vim_type_internal': vim.get('type')}
if vim["config"]:
extra.update(yaml.load(vim["config"]))
if vim.get('dt_config'):
db_sce_vnf = {
"uuid": sce_vnf_uuid,
"scenario_id": scenario_uuid,
- "name": existing_vnf[0]["name"][:200] + "." + get_str(vnf, "member-vnf-index", 5),
+ "name": get_str(vnf, "member-vnf-index", 255),
"vnf_id": existing_vnf[0]["uuid"],
"member_vnf_index": str(vnf["member-vnf-index"]),
# TODO 'start-by-default': True
image_uuid = vm['image_id']
if vm.get("image_list"):
for alternative_image in vm["image_list"]:
- if alternative_image["vim_type"] == vim["config"]["vim_type"]:
+ if alternative_image["vim_type"] == vim["config"]["_vim_type_internal"]:
image_uuid = alternative_image['image_id']
break
image_dict = mydb.get_table_by_uuid_name("images", image_uuid)