Fix stack status wait

The SDK side requires a stack object to be passed in when waiting for
the status change. This patch fixes the incorrect behavior we had --
passing a stack_id.

Change-Id: Ib92f5803abb70a0ac1014f42a8fd4de1e4c0ca91
This commit is contained in:
tengqm
2016-08-17 05:01:41 -04:00
parent 7ef904f4c5
commit 82ea6feaff
2 changed files with 18 additions and 5 deletions

View File

@@ -61,8 +61,10 @@ class HeatClient(base.DriverBase):
if timeout is None:
timeout = cfg.CONF.default_action_timeout
return self.conn.orchestration.wait_for_status(
stack_id, status, failures, interval, timeout)
stack_obj = self.conn.orchestration.find_stack(stack_id, False)
if stack_obj:
self.conn.orchestration.wait_for_status(
stack_obj, status, failures, interval, timeout)
@sdk.translate_exception
def wait_for_stack_delete(self, stack_id, timeout=None):