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

Bill Havanki commented on ZOOKEEPER-1954:
-----------------------------------------

Patch available for review.

> StaticHostProvider loses IPv6 scope ID when resolving server addresses
> ----------------------------------------------------------------------
>
>                 Key: ZOOKEEPER-1954
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1954
>             Project: ZooKeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.4.6
>            Reporter: Bill Havanki
>            Assignee: Bill Havanki
>            Priority: Minor
>         Attachments: ZOOKEEPER-1954.patch
>
>
> I have been getting constant failures of the {{ClientPortBindTest}} unit test 
> (see ZOOKEEPER-1256) on my Macbook. I traced the problem to loss of the IPv6 
> scope ID on the address chosen for the loopback address in the unit test.
> The address chosen is: fe80:0:0:0:0:0:0:1%1. The scope ID here is 1, after 
> the percent sign.
> The scope ID is lost in the {{resolveAndShuffle()}} method of 
> {{StaticHostProvider}}. The method uses {{InetAddress.getByAddress()}} which 
> apparently does not preserve the scope ID in the host string it is passed. 
> {{Inet6Address.getByAddress()}} can, although you have to parse the scope ID 
> out of the host string yourself and pass it as its own parameter.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to