The code designed to deal with the case where an in-progress StackResource
update is cancelled by stopping the update of the nested stack has never
worked because it was erroneously trying to catch StopIteration exceptions
instead of the actual exception raised when a generator is closed,
GeneratorExit.
This change moves the handling code to the new handle_update_cancel()
mechanism instead. Using this mechanism also means that StackResources will
be cancelled immediately, rather than waiting for up to error_wait_time
before cancelling the nested stack update. The previous patch adds a grace
period for IN_PROGRESS resources within the nested stack to complete, so we
want to notify it straight away to begin that period (and to not start any
new work).
Since the grace period on the child stack means that the child is likely to
still be IN_PROGRESS at the time we want to roll back, handle rollback by
sending an update-cancel with rollback message to the child. Only if the
child is no longer IN_PROGRESS will we start an update with the previous
template. If it is still IN_PROGRESS then just wait for it to reach
ROLLBACK_COMPLETE.
Change-Id: Ide210f695446fe8de2057b3b74c276165a6f9f3f
Closes-Bug: #1591337
Closes-Bug: #1446252
Now that there is a passing gate job, we can claim support for
Python 3.5 in the classifier. This patch also adds the convenience
py35 venv.
Change-Id: Ie64b63a462ae9b2c25ce9ab9e05259350353522e
This adds a new test which actually trigger the 'is_using_neutron'
resource method by creating a server using a port.
Change-Id: Ic9a3f42fa5b24048472256832496eb630cdba2c9
Neutron v2 client wraps SessionClient and it's
available as an attribute `httpclient'.
Change-Id: I664be1b00975b048e2289f5be3270b4a00520e80
Closes-Bug: #1607222
It seems at times it takes more time than the current default
for the child processes to exit normally. Increasing it to
120 seconds.
Change-Id: Ic54d2d7edc97cbe07ed4a4445cb865bd1b157f9d
Closes-Bug: #1607177
swiftclient doesn't use oslo_log and logs ERROR with TRACE for
response exceptions like 404. This isn't desirable for heat which
relies on 404s to know a delete is complete.
This change sets the swiftclient logging level to CRITICAL in the
client plugin.
Change-Id: Ie11a6d19068169424ee883ce428aad306d647f0d
Partial-Bug: #1606404
Recently we moved to use SessionClient with
the client plugins and it seems, just
creating the client does not ensure that the
service is available. We should check for
the endpoint.
Change-Id: Iae9fa8758314a4b04224127a181eb1054aa72d8a
Closes-Bug: #1606951
Now that we store the keystone session in the context,
we can use them to create the client plugins.
Change-Id: I9c870691ad5f6b1099dba51b5ef4c54360b65122
we can use assertEqual() instead of assertDictEqual().
This will make the unit test code more consistent,
and will also simplify the development of unit tests.
Change-Id: I31cee2db3b299c2c1e803666bc84b258c752e105
Passing empty section like parameters in the environment can leave the
user with a strange error message. This fixes the issue by providing a
correct error.
Change-Id: I766cd38e8a70c9f76cf10f540e22a929eaed3768
Closes-Bug: #1606148
Scaling policies(alarm_url) are normally expected to be
used with 'alarm_actions' of Alarm resource plugins by
the template author. However, we should not check for the
alarm state before proceeding on handling the signal.
This would provide flexibility to use these policies with
other alarm actions like 'insufficient_data_actions',
if required.
Change-Id: I733f986c9ac151f76aa997d26e9b9cf8afd9f6c9
Closes-Bug: #1598044
While testing I discovered a couple of corner cases not previously
handled:
- If you provide values/keys via a get_attr reference it's possible for
them to be None during validation
- If the input map has an unhashable value, it breaks the values replacement
so we need to tolerate a failure to lookup an unhashable key in the values
data.
Change-Id: I14d92056e0a07816a216aba752711887e8ac0aa5
Functions can't return functions, so we don't need to use `while`.
This doesn't change behaviour of code, just makes it more understandable
and convenient.
Change-Id: Ia1dac5a9583cb99db23a8838412e5bc02e93ef4c
I missed adding the reno in https://review.openstack.org/#/c/343731/
and there was a minor docs nit mentiond also.
Change-Id: Ib78ca19b96a239c0a06758c259e2e74e10ed26e5