summaryrefslogtreecommitdiffstats
path: root/lcm
diff options
context:
space:
mode:
authorYan Yang <yangyanyj@chinamobile.com>2018-04-13 01:01:51 +0000
committerGerrit Code Review <gerrit@onap.org>2018-04-13 01:01:51 +0000
commit24aaa782fcb3e543dcee8c18fae2101b1a46ffb9 (patch)
treef8cf275486ebc44b1c2d17fdb6a0da2b94f1344e /lcm
parentf0fad857a0045f3f14f36ecdc6b294b1b27df6c4 (diff)
parent68f003bbc30b5c8537fbefcfbd1517b393fea8b0 (diff)
Merge "Modify vfc-vnflcm vnf creation"
Diffstat (limited to 'lcm')
-rw-r--r--lcm/lcm/nf/vnf_create/create_vnf_identifier.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/lcm/lcm/nf/vnf_create/create_vnf_identifier.py b/lcm/lcm/nf/vnf_create/create_vnf_identifier.py
index 24768aea..34329a52 100644
--- a/lcm/lcm/nf/vnf_create/create_vnf_identifier.py
+++ b/lcm/lcm/nf/vnf_create/create_vnf_identifier.py
@@ -28,11 +28,9 @@ logger = logging.getLogger(__name__)
class CreateVnf:
def __init__(self, data):
self.data = data
- self.vnfd_id = ignore_case_get(self.data, "vnfdId")
+ self.csar_id = ignore_case_get(self.data, "vnfdId")
self.vnf_instance_mame = ignore_case_get(self.data, "vnfInstanceName")
self.description = ignore_case_get(self.data, "vnfInstanceDescription")
- self.vnfd = None
- self.csar_id = self.vnfd_id
def do_biz(self):
self.nf_inst_id = str(uuid.uuid4())
@@ -54,7 +52,7 @@ class CreateVnf:
vnfd_model='',
status='NOT_INSTANTIATED',
nf_desc=self.description,
- vnfdid=self.vnfd_id,
+ vnfdid=self.csar_id,
vnfSoftwareVersion='',
create_time=now_time())
vnf_inst = NfInstModel.objects.get(nfinstid=self.nf_inst_id)
@@ -94,6 +92,7 @@ class CreateVnf:
vnfd_model=self.vnfd_info,
status='NOT_INSTANTIATED',
nf_desc=self.description,
- vnfdid=self.vnfd_id,
+ vnfdid=self.csar_id,
vnfSoftwareVersion=vnfsoftwareversion,
create_time=now_time())
+ logger.debug('Create VNF instance[%s] success', self.nf_inst_id)