From: Ritu Sood Date: Wed, 16 May 2018 22:46:35 +0000 (-0700) Subject: Ignore flavors that don't have hpa-capabilities X-Git-Tag: v1.1.1~4 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F37%2F47837%2F1;p=optf%2Fhas.git Ignore flavors that don't have hpa-capabilities Multi-cloud creates some flavors without hpa-capabilities Issue-ID: OPTFRA-235 Change-Id: I4acfd6198bb0f494d0a34372d761c2dff7b4b301 Signed-off-by: Ritu Sood --- diff --git a/conductor/conductor/data/plugins/inventory_provider/hpa_utils.py b/conductor/conductor/data/plugins/inventory_provider/hpa_utils.py index 41e217c..3cd2cfb 100644 --- a/conductor/conductor/data/plugins/inventory_provider/hpa_utils.py +++ b/conductor/conductor/data/plugins/inventory_provider/hpa_utils.py @@ -74,8 +74,8 @@ class HpaMatchProvider(object): try: flavor_cap_list = flavor['hpa-capabilities'] except KeyError: - LOG.info(_LI("invalid JSON ")) - return None + LOG.info(_LI("hpa-capabilities not found in flavor ")) + continue for capability in CapabilityDataParser.get_item(flavor_cap_list, 'hpa-capability'): hpa_list = {k: capability.item[k] \