[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-836?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12964827#action_12964827
 ] 

Benjamin Reed commented on ZOOKEEPER-836:
-----------------------------------------

i agree that always starting at the beginning of the list will be a problem, 
but that shouldn't happen with StaticHostProvider. the iterator of the host 
list is a local variable that gets used on each call to next(), so you 
shouldn't go back to the beginning until you have gone through all the other 
hosts in the list.

> hostlist as string
> ------------------
>
>                 Key: ZOOKEEPER-836
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-836
>             Project: ZooKeeper
>          Issue Type: Sub-task
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Patrick Datko
>            Assignee: Thomas Koch
>         Attachments: ZOOKEEPER-836.patch, ZOOKEEPER-836.patch, 
> ZOOKEEPER-836_2.patch
>
>
> The hostlist is parsed in the ctor of ClientCnxn. This violates the rule of 
> not doing (too much) work in a ctor. Instead the ClientCnxn should receive an 
> object of class "HostSet". HostSet could then be instantiated e.g. with a 
> comma separated string.

-- 
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