summaryrefslogtreecommitdiffstats
path: root/ocata
diff options
context:
space:
mode:
authorBin Yang <bin.yang@windriver.com>2018-05-14 14:08:44 +0000
committerGerrit Code Review <gerrit@onap.org>2018-05-14 14:08:44 +0000
commit5c42c9de221ec679e8f25952015f4579e9bac3f7 (patch)
tree7e431e8961319564ce11bf6aa26cb2e198cc0c57 /ocata
parentb7cac6c5ac9fb85ccc4c3dab8b0eec39b2634892 (diff)
parentc074758add133192a47d6af72966594194e482d1 (diff)
Merge "Fix hpa registration cloud_extra_info format"
Diffstat (limited to 'ocata')
-rw-r--r--ocata/ocata/registration/views/registration.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/ocata/ocata/registration/views/registration.py b/ocata/ocata/registration/views/registration.py
index 4d954cb1..bb898995 100644
--- a/ocata/ocata/registration/views/registration.py
+++ b/ocata/ocata/registration/views/registration.py
@@ -318,6 +318,13 @@ class Registry(newton_registration.Registry):
feature_uuid = uuid.uuid4()
cloud_extra_info_str = viminfo.get('cloud_extra_info')
+ if not isinstance(cloud_extra_info_str, dict):
+ try:
+ cloud_extra_info_str = json.loads(cloud_extra_info_str)
+ except Exception as ex:
+ logger.error("Can not convert cloud extra info %s %s" % (
+ str(ex), cloud_extra_info_str))
+ return {}
if cloud_extra_info_str :
cloud_dpdk_info = cloud_extra_info_str.get("ovsDpdk")
if cloud_dpdk_info :