Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
BIGTOP-2476 Add Zookeeper Charm #15
Conversation
|
I have a couple issues with the status reporting
Followed by setting the appropriate message if we had a suboptimal quantity of peers: https://github.com/juju-solutions/layer-apache-zookeeper/blob/master/reactive/zookeeper.py#L44 If you brought this back, you could add a reactive handler like this:
|
petevg
commented
Jun 21, 2016
|
Fixed the status messages. I think that, with the messaging complexity we've introduced by not doing automatic restarts, I'd rather skip the notifications about inadequate numbers for quorum for now. When we add the automated restarts back in, though, I like the idea of adding those messages back in as well. |
petevg
commented
Jun 21, 2016
|
@kwmonroe I lied about the messing being too complex. Functionality from the old charm ported over. :-) |
kwmonroe
reviewed
Jun 22, 2016
| + | ||
| +def main(): | ||
| + LOG("starting restart handler main.") | ||
| + hookenv.status_set('waiting', 'Restarting ...') |
kwmonroe
reviewed
Jun 22, 2016
| + hookenv.status_set('waiting', 'Restarting ...') | ||
| + zookeeper = Zookeeper() | ||
| + zookeeper.install() | ||
| + hookenv.status_set('active', 'Ready {}'.format(zookeeper.quorum_check())) |
kwmonroe
reviewed
Jun 22, 2016
| + zookeeper.open_ports() | ||
| + set_state('zookeeper.installed') | ||
| + set_state('zookeeper.started') | ||
| + hookenv.status_set('active', 'Ready {}'.format(zookeeper.quorum_check())) |
petevg
added some commits
Jun 22, 2016
johnsca
reviewed
Jun 22, 2016
| + LOG("starting restart handler main.") | ||
| + hookenv.status_set('waiting', 'Restarting ...') | ||
| + zookeeper = Zookeeper() | ||
| + zookeeper.install() |
johnsca
Jun 22, 2016
Owner
This should be predicated on the zookeeper.started state and should action_fail if it's not set.
petevg
and others
added some commits
Jun 22, 2016
kwmonroe
reviewed
Jun 27, 2016
| + Run smoke tests. | ||
| + ''' | ||
| + for unit in self.d.sentry['zookeeper']: | ||
| + unit.action_do("smoke-test") |
kwmonroe
Jun 27, 2016
•
Member
there is no smoke-test action in this charm.. this isn't necessarily a bad thing since it will just pick up the default smoke-test from here:
https://github.com/juju-solutions/layer-apache-bigtop-base/blob/master/actions/smoke-test
just wanted to make sure you knew this would happen, and that there was no custom smoke-test handling required for zk.
petevg
Jun 28, 2016
@kwmonroe Yep. The default smoke test action is just fine for Zookeeper -- we don't need to do any special setup.
petevg
commented
Jun 28, 2016
|
I've opened a PR upstream, so closing out this PR. |
petevg commentedJun 17, 2016
•
Edited 1 time
-
petevg
Jun 17, 2016
Based on the vanilla apache-zookeeper charm, but utlizes Bigtop to
reduce complexity in the charm itself.
@juju-solutions/bigdata: Since I'm still a newb, I'm pushing one more PR w/ the team before submitting upstream. This, I think, is the final, actually working, following all the best practices version of this charm. If you agree, please +1. If I missed something, please let me know, and I'll fix it :-)