We are trying to introduce ZooKeeper SSL with many of our deployed components. Recently I had to debug an issue, where Kafka was unable to connect to ZooKeeper, because the SSL handshake took too much time and the connectTimeout elapsed in the client side. The connectTimeout is calculated based on the sessionTimeout currently and this is not very flexible / practical for certain use-cases.
I would have a proposal to introduce explicit sessionInitTimeout configuration in the java client (in a backward compatible way). Can I ask about your opinion on this? As I already created a Jira ticket (here: https://issues.apache.org/jira/browse/ZOOKEEPER-3827), I propose to discuss the topic there. Kind regards, Mate