Merge "Convergence: Avoid cache when resolving input data"
This commit is contained in:
commit
aad322c705
|
@ -334,15 +334,15 @@ def construct_input_data(rsrc, curr_stack):
|
|||
for attr in attributes:
|
||||
try:
|
||||
if isinstance(attr, six.string_types):
|
||||
resolved_attributes[attr] = rsrc.FnGetAtt(attr)
|
||||
resolved_attributes[attr] = rsrc.get_attribute(attr)
|
||||
else:
|
||||
resolved_attributes[attr] = rsrc.FnGetAtt(*attr)
|
||||
resolved_attributes[attr] = rsrc.get_attribute(*attr)
|
||||
except exception.InvalidTemplateAttribute as ita:
|
||||
LOG.info(six.text_type(ita))
|
||||
|
||||
input_data = {'id': rsrc.id,
|
||||
'name': rsrc.name,
|
||||
'reference_id': rsrc.FnGetRefId(),
|
||||
'reference_id': rsrc.get_reference_id(),
|
||||
'attrs': resolved_attributes,
|
||||
'status': rsrc.status,
|
||||
'action': rsrc.action,
|
||||
|
|
|
@ -621,7 +621,7 @@ class MiscMethodsTest(common.HeatTestCase):
|
|||
'uuid': mock.ANY,
|
||||
'action': mock.ANY,
|
||||
'status': mock.ANY}
|
||||
self.resource.FnGetAtt = mock.Mock(
|
||||
self.resource.get_attribute = mock.Mock(
|
||||
side_effect=exception.InvalidTemplateAttribute(resource='A',
|
||||
key='value'))
|
||||
actual_input_data = worker.construct_input_data(self.resource,
|
||||
|
|
Loading…
Reference in New Issue