GitHub user geomacy opened a pull request:
https://github.com/apache/brooklyn-server/pull/530
JcloudsLocation is not releasing its customizers (BROOKLYN-427)
preRelease and postRelease of JcloudsLocationCustomizers are not being
called as expected during the release of a Jclouds machine location.
The problem is that the "setup" used in JcloudsLocation.obtainOnce includes
a copy of the flags passed from
MachineLifecycleEffectorTasks#stopAnyProvisionedMachines,
which includes the customizers. However, the "setup" used in the "release"
method of JcloudsLocation is taken from the JcloudsLocation itself, which
is the provisioning (i.e. parent) location, which doesn't have those
customizers in it.
It would actually make more sense to get the location customizers from
the machine location, as a given parent could have mutiple machines
with different customizers.
The changes here include an addition to the
`JcloudsCustomizerInstantiationYamlDslTest#testCustomizers`
to demonstrate the problem, and a fix that adds the config to
the machine location.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/geomacy/brooklyn-server jclc-release
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/brooklyn-server/pull/530.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #530
----
commit 7b805a73da1b75de1f0f0b981f377c83ffb37bb9
Author: Geoff Macartney <[email protected]>
Date: 2017-01-19T17:10:45Z
preRelease and postRelease of JcloudsLocationCustomizers are not called on
stop
commit 432823a333929ba58cad7d5219679c78e3e92ac8
Author: Geoff Macartney <[email protected]>
Date: 2017-01-19T17:28:31Z
Fix broken test for preRelease/postRelease
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---