You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Yaohui Wu (JIRA)" <ji...@apache.org> on 2017/01/11 08:58:58 UTC

[jira] [Resolved] (ZOOKEEPER-2661) It costs about 5055 ms to create Zookeeper object for the first time.

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

Yaohui Wu resolved ZOOKEEPER-2661.
----------------------------------
    Resolution: Not A Problem

I solve it by adding one line to /etc/hosts:
::1 YaohuideMacBook-Air.local
'YaohuideMacBook-Air.local' is my host name. Now the problem disappears. It only cost 86 ms to create Zookeeper the first time.
16:47:43.106 109 INFO org.example.zk.curator.ZookeeperTest - cost 86 ms

> It costs about 5055 ms to create Zookeeper object for the first time.
> ---------------------------------------------------------------------
>
>                 Key: ZOOKEEPER-2661
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2661
>             Project: ZooKeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.4.6
>         Environment: See the description below.
>            Reporter: Yaohui Wu
>         Attachments: ZookeeperTest.java, log_output.txt
>
>
> I create and close ZooKeeper for 10 times.  It costs about 5055 ms for the first time.
> See attached files for some test code and output.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)