summaryrefslogtreecommitdiffstats
path: root/share/common/msapi/helper.py
diff options
context:
space:
mode:
authorXiaohua Zhang <xiaohua.zhang@windriver.com>2019-04-10 08:51:19 +0000
committerXiaohua Zhang <xiaohua.zhang@windriver.com>2019-04-10 09:48:26 +0000
commit2024bb59b1d4ec20300304aed3a69132b9c082bc (patch)
tree349a90cd5fc0c64335142c09bd76db86e3d2d7e7 /share/common/msapi/helper.py
parent14132a2c06bc6b6431f5be90cecf303132d94103 (diff)
Fix bug of AZ cap check
Fix bugs in restcall module update the status code of workload api Remove unused event api from lenovo Change-Id: Iaa16bc3aca42c4583408384c73802ff4debe1b19 Issue-ID: MULTICLOUD-542 Signed-off-by: Xiaohua Zhang <xiaohua.zhang@windriver.com>
Diffstat (limited to 'share/common/msapi/helper.py')
-rw-r--r--share/common/msapi/helper.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/share/common/msapi/helper.py b/share/common/msapi/helper.py
index 947966c9..69b91953 100644
--- a/share/common/msapi/helper.py
+++ b/share/common/msapi/helper.py
@@ -13,12 +13,10 @@ import json
import logging
# import re
import uuid
-
import threading
import datetime
import time
-
-import traceback
+#import traceback
# from common.exceptions import VimDriverNewtonException
from common.utils import restcall
@@ -75,7 +73,7 @@ class MultiCloudAAIHelper(object):
'''
def __init__(self, multicloud_prefix, aai_base_url):
- logger.debug("MultiCloudAAIHelper __init__ traceback: %s" % traceback.format_exc())
+ # logger.debug("MultiCloudAAIHelper __init__ traceback: %s" % traceback.format_exc())
self.proxy_prefix = multicloud_prefix
self.aai_base_url = aai_base_url
self._logger = logger
@@ -203,7 +201,7 @@ class MultiCloudThreadHelper(object):
self.expired_backlog = {}
self.lock = threading.Lock()
self.state_ = 0 # 0: stopped, 1: started
- self.cache_prefix = "bi_"+name+"_"
+ self.cache_prefix = "bi_"+self.name+"_"
self.cache_expired_prefix = "biex_"+self.name+"_"
self.thread = MultiCloudThreadHelper.HelperThread(self)
@@ -317,7 +315,7 @@ class MultiCloudThreadHelper(object):
# sleep in case of interval > 1 second
time.sleep(nexttimer // 1000000)
nexttimer = 30*1000000 # initial interval in us to be updated:30 seconds
- # logger.debug("self.owner.backlog len: %s" % len(self.owner.backlog))
+ # logger.debug("self.owner.backlog: %s, len: %s" % (self.owner.name, len(self.owner.backlog)))
for backlog_id, item in self.owner.backlog.items():
# logger.debug("evaluate backlog item: %s" % item)
# check interval for repeatable backlog item