Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

If the URL protocol is either HTTP or file, then the client library will periodically check the resource and update its in-core server list. If the protocol is “zk” zkor the traditional connection string is used, then the client library will periodically resolve the DNS names, if needed. The refresh and/or name resolution will be enabled by default.

...

TBD: We could add a new constructor to specify these options, but I prefer it would be good to avoid creating new constructors for every feature.

If the server list retrieved from the URL does not include the server that the client is currently connected to, then the client will disconnect from the server and attempt to reconnect to other servers (using the new list). Otherwise, the new list will be used next time when the client attempts to connect to a server.

The server list stored in the URL will be the usual ZooKeeper configuration file (zoo.cfg) with the following exceptions:

  1. A new optional property “version” versionwill added to the configuration file. The version number indicates the reconfiguration version number and should match the version number of the current server configuration returned by ZooKeeper.getConfig() (see [1],[2] for further details). The version number, when specified, will be used to ensure that the client will be choose the new server list only if the version number of the list is higher than the current version number.
  2. The “server.x=host:serverPort:electionPort” property will be changed to “server.x=host:serverPort:electionPort:clientPort”.

...

Wiki Markup
<ac:structured-macro ac:name="anchor" ac:schema-version="1" ac:macro-id="2ae524a9bcc32d36-c2e8e9a0-4d864a48-ab509060-72695e4020eea367fef42f04"><ac:parameter ac:name="">107</ac:parameter></ac:structured-macro> \[1\]  JIRA for dynamic cluster membership. [https://issues.apache.org/jira/browse/ZOOKEEPER-107]

Wiki Markup
<ac:structured-macro ac:name="anchor" ac:schema-version="1" ac:macro-id="2c5a560701c989cd-80a5ff94-4ee948d0-84ec8e69-d2c024b525ee8f3d444f82b7"><ac:parameter ac:name="">107wiki</ac:parameter></ac:structured-macro> \[2\] Cluster Membership. [https://cwiki.apache.org/confluence/display/ZOOKEEPER/ClusterMembership]