We have a "see also" in the shorter constructor over to this which has
the detail:
http://hadoop.apache.org/zookeeper/docs/r3.0.1/api/org/apache/zookeeper/ZooKeeper.html#ZooKeeper(java.lang.String,%20int,%20org.apache.zookeeper.Watcher,%20long,%20byte[])
We should copy/paste the docs instead to make it more clear.
We don't currently talk about this in the main documentation (prog
guide) which is a mistake, I've entered a jira for this:
https://issues.apache.org/jira/browse/ZOOKEEPER-263
Patrick
Thomas Vinod Johnson wrote:
Kevin Burton wrote:
The ZooKeeper constructor only takes a host and port... not a list of
servers.
The second constructor documents the host parameter as follows:
@param host comma separated host:port pairs, each corresponding to a zk
server. eg. "127.0.0.1:3000,127.0.0.1:3001,127.0.0.1:3002"
I assumed you communicated with on server by default, and that server
then
passed you the list of all known servers.
Am I missing something?
Kevin