_eventThread.start();
_connection.connect(watcher);
LOG.debug("Awaiting connection to Zookeeper server: " + maxMsToWaitUntilConnected);
if (!waitUntilConnected(maxMsToWaitUntilConnected, TimeUnit.MILLISECONDS)) {
throw new ZkTimeoutException(String.format(
"Unable to connect to zookeeper server[%s] within timeout %dms", _connection.getServers(), maxMsToWaitUntilConnected));
}
started = true;
} catch (InterruptedException e) {
States state = _connection.getZookeeperState();