import getpass
import logging
import pkg_resources
+import pprint
import socket
import tempfile
import time
from oslo_serialization import jsonutils
from oslo_utils import encodeutils
import shade
+from shade._heat import event_utils
import yardstick.common.openstack_utils as op_utils
from yardstick.common import exceptions
self._update_stack_tracking()
+ def get_failures(self):
+ return event_utils.get_events(self._cloud, self._stack.id,
+ event_args={'resource_status': 'FAILED'})
+
def get(self):
"""Retrieves an existing stack from the target cloud
return stack
if stack.status != self.HEAT_STATUS_COMPLETE:
+ for event in stack.get_failures():
+ log.error("%s", event.resource_status_reason)
+ log.error(pprint.pformat(self._template))
raise exceptions.HeatTemplateError(stack_name=self.name)
log.info("Creating stack '%s' DONE in %d secs",