Correct function name in description for test function.
Also correct function sample in hot function class `MapMerge`.
Change-Id: I61acec48e4a8365940d3e6e3d0a93d0c58fbda43
If stack-show is called at an inopportune moment in convergence, we can
attempt to store the attributes of a resource that isn't actually in the
database. This causes occasional gate failures due to an assert.
Closes-Bug: #1701569
Change-Id: I50de08ae6b40958781ef4223c82a5c195b0757bf
Calculating all of the attributes of a resource that are referenced in the
template was previously done inside the node_data() method, but this is
useful for the resource to be able to access for other reasons so refactor
it into a separate method.
Change-Id: I8ec943652e6f93a2352f2ea5e6ac46e0088e5458
Related-Bug: #1660831
Partially-Implements: blueprint stack-definition
This helps with dynamically building templates, and is similar to the
add_resource method.
Change-Id: I51ce5c913438083d6d43eb6d8a8bf55cfa8ea3ee
Related-Bug: #1660831
We use StackValidationFailed in many different scenarios and
the the message is at times extremely unhelpful, specifically
when the validation error is deep in a nested stack.
Change-Id: I0183bdf81442e62325a427b4eec5c4cd9b7cb91f
Closes-Bug: #1686360
This changes the logic of getting cancellation grace
period of task runner before closing it: to move the
liveness check into the cancel_all() method in the
scheduler rather than ask the resource if it's IN_PROGRESS.
Change-Id: Ia2a03de227ff15cdce1b3dbb6cd6bff6c5a50a15
Partial-Bug: 1693495
This moves signal validation after hook handling, to be able to properly
get signals during DELETE actions.
Change-Id: I18e2284ab344f6c2e46e40744b771524b7bad9d9
Closes-Bug: #1690806
With the added get_rpc_transport() function in oslo.messaging [1]
and the recent version bump of oslo.messaging to 5.24.2, we can
safely replace get_transport() with get_rpc_transport() which is much
cleaner.
[1] https://review.openstack.org/#/c/454194/
Change-Id: I7de089b7352dd9e45a519fc03035c5a39812c1b3
Previously, all caching of attribute values was done via the Attributes
object. However, some resource types override Resource.get_attribute() to
do custom handling of the trailing attribute path or dynamic attribute
names, and in these cases the resulting values were not cached (since they
don't go through the Attributes object).
This patch adds a caching step for these resources:
* OS::Senlin::Cluster
* OS::Heat::ResourceChain
* OS::Heat::ResourceGroup
* OS::Heat::AutoscalingGroup
* OS::Heat::SoftwareDeployment
* OS::Heat::SoftwareDeploymentGroup
* TemplateResource
* AWS::CloudFormation::Stack
Change-Id: I07ac22cc4370a79bd8712e2431fa3272115bc0eb
Co-Authored-By: Crag Wolfe <cwolfe@redhat.com>
Partial-Bug: #1660831
Add a new OS::Neutron::Trunk resource and support the creation,
deletion and update of Neutron Trunks.
Co-Authored-By: Bence Romsics <bence.romsics@ericsson.com>
Co-Authored-By: David Toth <david.t.toth@ericsson.com>
Change-Id: Iea12844f77abf8c254f6224d55470663eba66aab
Implements: blueprint support-trunk-port
This code was never used for anything, as the rest of the patch series
never landed and was abandoned.
This reverts commit 15e52ff5e9.
Change-Id: I7d1a22753e8de1d3adf127c14516ebd667513bfa
Combination alarm has been removed from Aodh since Pike.
We inherit combination alarm from none resource in this patch.
Will schedule to remove the resource in future cycle.
Closes-Bug: #1668342
Change-Id: I573f4bde9b4b7b12879c39111cf87c751f71ad7e
This patch add `is_placeholder` key in resource data for placeholder
resource like none resource. And prevent any delete action if key
founded in resource data. We put `is_placeholder` key for none resource
to let it replace existence resource type and still allow exists
resources of that type (which should not contain is_placeholder key in
resource data) will be able to delete those resources.
Partial-Bug: #1668342
Change-Id: I379cd732639a58b92986a5c22d7555b719bdcb39
The patch at I1cb321a3878a0abce9b41832f76bf77c25bf7cb4 properly deleted
the snapshots from the database, but as delete in convergence sets the
template to an empty template, stack.resources is empty. This works
around the problem by deleting the snapshots beforehand.
Related-Bug: #1508299
Change-Id: Id1c2c1a293fdcda07c527f29fedc00b716b303bc
It's possibile for resource listing of a legacy stack with an update
in progress to have resources in db but not in template.
Probably it would not hurt to filter those out.
Change-Id: I84e56ba88270079acbfcdc6227c4263b39956fe6
Closes-Bug: #1653990
assertRaisesRegexp was renamed to assertRaisesRegex since Py3.2
For more details, please check:
https://docs.python.org/3/library/
unittest.html#unittest.TestCase.assertRaisesRegex
Change-Id: I3481fe4a0526f4703a753282464f17345df8aa78
During stack updates in the legacy path, we copy resource definitions
back and forth between templates. In the case where the definitions
contain macros (which in practice means the If macro for conditionals),
they may rely on external state (in practice, the conditional
definitions) that is not available in the template they're being copied
into (e.g. in the case of an If macro referencing a new condition).
This change means that when we copy a template, the macros get resolved
so that only the chosen path of the If macro is represented.
This resolves the issue where trying to signal a resource during an
update fails when one of the already-updated resources in the template
contains an If macro that refers to a condition definition that is
newly-added in the new template.
Change-Id: I6d08507f43b0fcc4c0b5e848e97fa26033d839b2
Closes-Bug: #1699463
This adds OS::Zun::Container to the Zun resources
Co-Authored-By: Hongbin Lu <hongbin.lu@huawei.com>
Implements: blueprint heat-plugin-zun
Change-Id: I979d9593fb25bd2c7df99411a6a5bbe402799f61
Previously, we were not using the specialized parameter class' __str__
method to print the parameters in the stack-show output with python
2.x.
Closes-Bug: #1613415
Change-Id: I44295ae567cef91eb484201099c7646cdb16fe08
Store rsrc_data 'metadata_queue_id' after zaqar queue
created, to avoid unnecessary queue delete calling when
delete nova server.
Change-Id: Ib1f7759ea66794ebd57fcfcea6b9e596b0e2c1c3
Closes-Bug: #1697682