diff options
author | 2017-09-08 09:08:09 +0800 | |
---|---|---|
committer | 2017-09-08 09:08:09 +0800 | |
commit | ffd4c835081dd04f0f56e54a3f6bf27f7ca0ae59 (patch) | |
tree | d54144140de07eea9b6bfabdfe00957c36231314 /lcm/pub/msapi/aai.py | |
parent | 8f8e3d5d7a368e2b7f2f6f19a46d3ebb2e1f05d4 (diff) |
Update query vnfms api in vfc lcm extsys
Change-Id: I2c4c0718e7fc1ccea82dcf36e508fed1402242fc
Issue-ID: VFC-313
Signed-off-by: ying.yunlong <ying.yunlong@zte.com.cn>
Diffstat (limited to 'lcm/pub/msapi/aai.py')
-rw-r--r-- | lcm/pub/msapi/aai.py | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/lcm/pub/msapi/aai.py b/lcm/pub/msapi/aai.py index 1d1b3916..2666807f 100644 --- a/lcm/pub/msapi/aai.py +++ b/lcm/pub/msapi/aai.py @@ -214,25 +214,6 @@ def convert_vnfm_info(vnfm_info_aai): return vnfm_info -def select_vnfm(vnfm_type, vim_id): - uri = '/external-system/esr-vnfm-list' - ret = call_aai(uri, "GET") - if ret[0] > 0: - logger.error("Failed to call %s: %s", uri, ret[1]) - raise NSLCMException('Failed to get vnfms from extsys.') - vnfms = json.JSONDecoder().decode(ret[1]) - vnfms = ignore_case_get(vnfms, "esr-vnfm") - for vnfm in vnfms: - esr_system_info = ignore_case_get(vnfm, "esr-system-info") - type = ignore_case_get(esr_system_info, "type") - vimId = vnfm["vnfm-id"] - if type == vnfm_type and vimId == vim_id: - # convert vnfm_info_aai to internal vnfm_info - vnfm = convert_vnfm_info(vnfm) - return vnfm - raise NSLCMException('No vnfm found with %s in vim(%s)' % (vnfm_type, vim_id)) - - def get_vim_by_id(vim_id): cloud_owner, cloud_region = split_vim_to_owner_region(vim_id) ret = call_aai("/cloud-infrastructure/cloud-regions/cloud-region/%s/%s" % (cloud_owner, cloud_region), "GET") |