HubSpot/Baragon — pull request #3 by HiJon89 (2014-09-05 21:14:47+00:00)
Title: Global state node

For service discovery we need up-to-date data on every service, but creating watchers on every individual service node won't work. This stores a serialized version of all of the `BaragonServiceState` objects in the root `/status` node (currently no data is being stored there). Clients can then watch this one node for changes and maintain a complete picture of the world.

Since only the leader writes to these nodes, an `InterProcessLock` shouldn't be needed, I just made the relevant method `synchronized`.

@tpetr @wsorenson