SELECT=('vms.uuid as uuid', 'vms.osm_id as osm_id', 'vms.name as name', 'vms.description as description',
'boot_data'),
WHERE={'vnfs.uuid': vnf_id} )
- if len(content)!=0:
+ if len(content) != 0:
#raise NfvoException("vnf '{}' not found".format(vnf_id), HTTP_Not_Found)
# change boot_data into boot-data
for vm in content:
vm["boot-data"] = yaml.safe_load(vm["boot_data"])
del vm["boot_data"]
- data['vnf']['VNFC'] = content
+ data['vnf']['VNFC'] = content
#TODO: GET all the information from a VNFC and include it in the output.
#GET NET
raise NfvoException("Cannot find the vdu with id {}".format(vdu_id), HTTP_Not_Found)
else:
if not osm_vdu_id and not member_vnf_index:
- raise NfvoException("Invalid imput vdu parameters. Must supply either 'vdu-id' of 'osm_vdu_id','member-vnf-index'")
+ raise NfvoException("Invalid input vdu parameters. Must supply either 'vdu-id' of 'osm_vdu_id','member-vnf-index'")
target_vms = mydb.get_rows(
# SELECT=("ivms.uuid", "ivnfs.datacenter_id", "ivnfs.datacenter_tenant_id"),
FROM="instance_vms as ivms join instance_vnfs as ivnfs on ivms.instance_vnf_id=ivnfs.uuid"\
" join sce_vnfs as svnfs on ivnfs.sce_vnf_id=svnfs.uuid"\
" join vms on ivms.vm_id=vms.uuid",
- WHERE={"vms.osm_id": osm_vdu_id, "svnfs.member_vnf_index": member_vnf_index},
+ WHERE={"vms.osm_id": osm_vdu_id, "svnfs.member_vnf_index": member_vnf_index,
+ "ivnfs.instance_scenario_id": instance_id},
ORDER_BY="ivms.created_at"
)
if not target_vms: