zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anmolnar <...@git.apache.org>
Subject [GitHub] zookeeper pull request #451: ZOOKEEPER-2184: Zookeeper Client should re-reso...
Date Sun, 27 May 2018 20:55:54 GMT
Github user anmolnar commented on a diff in the pull request:

    --- Diff: src/java/main/org/apache/zookeeper/client/HostProvider.java ---
    @@ -53,7 +54,7 @@
          * @param spinDelay
          *            Milliseconds to wait if all hosts have been tried once.
    -    public InetSocketAddress next(long spinDelay);
    +    public InetSocketAddress next(long spinDelay) throws UnknownHostException;
    --- End diff --
    That's actually a great idea. I've tried that and `socket.connect()` will throw an IOException
eventually of the address is not resolved. Which means basically that the same retry logic
applies in the caller, it's just not next() that catches the error. I'll update the patch.
    Once this one is finally merged, I'll take a look at 3.5/master branches, because I think
we should be consistent with this across the board.


View raw message