sleep before waiting requests
to avoid issue with fast completing requests we need
to sleep a little before actual waiting for requests.
Closes-bug: 1596553
Change-Id: I17993f091241243eea670c7cf591ddd9c23d069c
(cherry picked from commit ef00d94635
)
This commit is contained in:
parent
22f9a9536a
commit
a41bb2548d
|
@ -251,6 +251,7 @@ class AmbariClient(object):
|
|||
def wait_ambari_requests(self, requests, cluster_name):
|
||||
requests = set(requests)
|
||||
failed = []
|
||||
context.sleep(20)
|
||||
while len(requests) > 0:
|
||||
completed, not_completed = set(), set()
|
||||
for req_id in requests:
|
||||
|
@ -281,6 +282,7 @@ class AmbariClient(object):
|
|||
LOG.debug("All ambari requests have been completed")
|
||||
|
||||
def wait_ambari_request(self, request_id, cluster_name):
|
||||
context.sleep(20)
|
||||
while True:
|
||||
status = self.check_request_status(cluster_name, request_id)
|
||||
LOG.debug("Task %s in %s state. Completed %.1f%%" % (
|
||||
|
|
Loading…
Reference in New Issue