[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-146?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jakob Homan updated ZOOKEEPER-146:
----------------------------------

    Attachment: ZOOKEEPER-146.patch

This patch:
   * Creates a new HostsProvider interface with one method (getHosts()) and two 
implementations of this method, StringHostsProvider and URLHostsProvider that 
return the list of hosts from either of those sources.  The StringHostsProvider 
provides the same functionality that there currently is, and URL will go grab 
the string from http/file/etc.
   * Creates two new constructors for ZooKeeper to use URLs rather than strings.
   * Provides unit tests for the two new concrete classes.

The patch doesn't change much of the inner workings of the ZooKeeper or 
ClientCnxn class, just grabs the string from the provider.  It would be 
possible to improve disconnect behavior by checking to see if there are new 
hosts available before connecting.

> Allow clients to retrieve the list of hosts/servers from a URL
> --------------------------------------------------------------
>
>                 Key: ZOOKEEPER-146
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-146
>             Project: Zookeeper
>          Issue Type: Improvement
>          Components: java client
>    Affects Versions: 3.0.0
>            Reporter: Jakob Homan
>            Assignee: Jakob Homan
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-146.patch
>
>
> As I suggested in ZOOKEEPER-107, it would be nice to allow clients to specify 
> their hosts strings via a URL so that this can change dynamically.  For 
> instance, obtain the current list of hosts from a webpage or a file on disk.  

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to