Need upgrade path from non-reactive charms to reactive #77

Open
johnsca opened this Issue Jul 7, 2016 · 4 comments

Comments

Projects
None yet
4 participants
Owner

johnsca commented Jul 7, 2016

Doing in-place upgrades from a non-reactive charm to a reactive implementation is difficult primarily due to needing to get the reactive states set up to reflect the environment as is currently deployed. Part of this can be done in an @hook('upgrade-charm') handler, but we at a minimum need some sort of helper to get the interface layers to the correct state.

Owner

johnsca commented Jul 7, 2016

One option might be to "fake" the -relation-joined and -relation-changed hooks for every relation to allow the interface layers to get their states in place. There are likely idempotency issues in some interface layers. Also, we might have to run only the hook phase for this, though, because the charm might try to react to the join in a non-idempotent way.

@chuckbutler chuckbutler closed this Jul 7, 2016

@chuckbutler chuckbutler reopened this Jul 7, 2016

Contributor

mbruzek commented Jul 9, 2016

An issue I have experienced is charms written in python version 2 not running in xenial 16.04 because only python version 3 (python3) is installed by default on xenial cloud images.

This is technically not a non-reactive to reactive issue, but we may need to ensure that the python code is up to version 3 standards as all reactive charms are generated with python3 shebangs.

Owner

johnsca commented Jul 11, 2016

@mbruzek You could also manually install python2 in a sort of pre-install hook, as a quick-fix. Though there are some difficulties in managing this now because there is no longer a guarantee that install will be the first hook run (leadership and storage hooks could both potentially run before install, and there might be others).

One thought for the Precise chamrs. Perhaps we deprecate precise ahead of its EOL, and state that reactive Precise charms are not supported. An even bigger statement we could make is that Juju Curated Charms do not support Precise.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment