GitHub user ahgittin opened a pull request:
https://github.com/apache/brooklyn-server/pull/872
Bundle/catalog upgrade headers to specify upgrade maps
For indicating that bundles or types are valid upgrade targets for other
items.
This does all the setup and tests (WIP) for when we actually apply upgrades
-- in following PRs. This does not apply any of the upgrade info it collects!
But it does parse the headers and test them in lots of variants, and lots of
tidies up to related recent code.
The first of the follow-on PRs will apply upgrades if a type is not found
(eg because we removed it), necessary for a clean update path. After that will
look at letting user trigger updates.
As this PR mainly affects test code it should be fairly safe, even if quite
involved in places. I suggest it isn't necessary to solve every corner case
just yet (though I'm not aware of any that aren't), so long as the main upgrade
paths are working (which will usually be the default `*` - the other complexity
shouldn't often be needed.)
Some minor changes to type lookup, to accept OSGi-equivalent versions, and
give a canonical order; also to node state, being more informative about saying
it is up. Major changes to some of the tests, esp around the `REMOVE` headers
in #866, to allow the same set of tests to run in HA Hot Standby or Master
configuration, and to speed up tests (reuse osgi except in Integration).
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/ahgittin/brooklyn-server
bundle-upgrade-actually-remove
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/brooklyn-server/pull/872.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 #872
----
commit 7b92932009453c22f62e97310a411893e116dd6f
Author: Alex Heneveld <[email protected]>
Date: 2017-10-30T10:21:39Z
remove code duplication in tests, run more standby
refactor using fixtures to run more tests in both terminate-then-rebind and
standby-promote modes,
without duplicating assertions
commit 305df9c321818308d58caf80693bc56c4e0d6b1f
Author: Alex Heneveld <[email protected]>
Date: 2017-10-30T14:47:34Z
fix too-early detection of standby promotion in tests, with definitive
mgmt.getNodeState()
and make reused OSGi framework the default (much faster) with more tests
commit b539605ff4b1ad313812fef81fe326de8478e31e
Author: Alex Heneveld <[email protected]>
Date: 2017-10-30T15:56:58Z
fix ordering of catalog lookup, and tidy naming of tests for rebind with
catalog upgrades
commit d64ca16b5c8b198183e3a870cbfe5a83f4197570
Author: Alex Heneveld <[email protected]>
Date: 2017-10-30T22:45:03Z
rebuild test JARs for use with new major version, and update tests that so
depend
commit 9173183f247add9a99316c6f5276b28a45429d62
Author: Alex Heneveld <[email protected]>
Date: 2017-10-30T22:38:03Z
more tests, warning messages, prep for upgrading bundles and types
commit 00df1d54369c0f5da8d1467e23a8d532a88ceb54
Author: Alex Heneveld <[email protected]>
Date: 2017-10-31T01:05:15Z
expand semantics of '*' for catalog remove headers, and more tests (prep
for upgrades)
commit 8473fb4be2c21d275bab8b2c92880abcf83eb68a
Author: Alex Heneveld <[email protected]>
Date: 2017-10-31T09:34:25Z
maps for upgrade types and bundles, and related test fixes incl tidy HA
transition clearing
fix recent rebind header tests which i forgot to test in previous, some
subtle HA behaviours,
but now all fixed and documented.
need to clear type registry as part of other clears on HA promotion fail
commit af3f5f511b44d0248acd7fd254f6aee8783ad811
Author: Alex Heneveld <[email protected]>
Date: 2017-10-31T12:36:55Z
parse upgrade maps and test that
commit c840fbe9f027a2f9c253f5ddbaa815e3ff0bd475
Author: Alex Heneveld <[email protected]>
Date: 2017-10-31T12:53:16Z
test tidy, accept osgi version equality when loading types, remove warns
tests with comments ready for ugprades
(type registry lookup still prefers exact non-osgi version match but will
use osgi)
----
---