You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Sean Bridges (JIRA)" <ji...@apache.org> on 2013/02/26 19:46:14 UTC

[jira] [Created] (ZOOKEEPER-1652) zookeeper java client does a reverse dns lookup when connecting

Sean Bridges created ZOOKEEPER-1652:
---------------------------------------

             Summary: zookeeper java client does a reverse dns lookup when connecting
                 Key: ZOOKEEPER-1652
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1652
             Project: ZooKeeper
          Issue Type: Bug
          Components: java client
    Affects Versions: 3.4.5
            Reporter: Sean Bridges
            Priority: Critical


When connecting to zookeeper, the client does a reverse dns lookup on the hostname.  In our environment, the reverse dns lookup takes 5 seconds to fail, causing zookeeper clients to connect slowly.

The reverse dns lookup occurs in ClientCnx in the calls to adr.getHostName()

{code}
            setName(getName().replaceAll("\\(.*\\)",
                    "(" + addr.getHostName() + ":" + addr.getPort() + ")"));
            try {
                zooKeeperSaslClient = new ZooKeeperSaslClient("zookeeper/"+addr.getHostName());
            } catch (LoginException e) {
{code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira