Skip to content

Instantly share code, notes, and snippets.

Last active October 11, 2015 23:27
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save ericacm/3935889 to your computer and use it in GitHub Desktop.
def watchLeaderChildren() {
new CuratorWatcher {
def process(event: WatchedEvent) {
val cs = clusterStatus()
// Do something with cluster status (log leadership change, etc)
// Re-set watch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment