# Create VNFR
needed_vnfds = {}
- for member_vnf in nsd["constituent-vnfd"]:
+ for member_vnf in nsd.get("constituent-vnfd", ()):
vnfd_id = member_vnf["vnfd-id-ref"]
step = "getting vnfd id='{}' constituent-vnfd='{}' from database".format(
member_vnf["vnfd-id-ref"], member_vnf["member-vnf-index"])
# vim-id # TODO it would be nice having a vim port id
}
vnfr_descriptor["connection-point"].append(vnf_cp)
- for vdu in vnfd["vdu"]:
+ for vdu in vnfd.get("vdu", ()):
vdur = {
"vdu-id-ref": vdu["id"],
# TODO "name": "" Name of the VDU in the VIM