Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
..
Failed to load latest commit information.
images
README.adoc
ghpages.sh
intro.adoc
spring-cloud-zookeeper.adoc

README.adoc

Build Status

Zookeeper overview

ZooKeeper is a centralized service for maintaining configuration information, naming, providing distributed synchronization, and providing group services. See the Zookeeper site for more information. Spring Cloud Zookeeper also builds on the Apache Curator project, which started life at Netflix.

Spring Cloud Zookeeper Features

Spring Cloud Zookeeper includes the following features:

  • Spring Cloud DiscoveryClient implementation (supports Ribbon and Zuul)

  • Zookeeper-based PropertySource loaded during the 'bootstrap' phase

Running the Sample

  1. Install zookeeper (On a mac with homebrew, use brew install zookeeper).

  2. Start zookeeper.

  3. Verify zookeeper is running.

  4. Run mvn --settings .settings.xml package. Doing so brings in the required Spring Cloud Maven repositories and Build.

  5. Run java -jar spring-cloud-zookeeper-sample/target/spring-cloud-zookeeper-sample-1.2.0.BUILD-SNAPSHOT.jar.

  6. Visit http://localhost:8080 to verify that {"serviceId":"testZookeeperApp","host":"<yourhost>","port":8080} works.

  7. Run java -jar spring-cloud-zookeeper-sample/target/spring-cloud-zookeeper-sample-1.2.0.BUILD-SNAPSHOT.jar --server.port=8081

  8. Visit http://localhost:8080 again to verify that {"serviceId":"testZookeeperApp","host":"<yourhost>","port":8081} eventually shows up in the results in a round-robin fashion. (It may take a minute or so.)