The client library is in charge of preventing expirations, if it happens it is 
probably because of dead servers or network problems that caused a spike in 

Increasing your session timeout helps prevent this.

If/when it happens, you need create another ZooKeeper object to reconnect to 
ZooKeeper. If you had any ephemeral nodes, they will be gone. For 
applications that are just reading things from ZooKeeper or updating status 
znodes the recovery is very simple. For master applications that setup 
complex ZooKeeper subtrees with ephemeral znodes at initialization, they need 
to rerun initialization logic. From ZooKeeper's point of view, the 
application has restarted when a new ZooKeeper object is recreated.


On Tuesday 17 June 2008 00:34:58 Avinash Lakshman wrote:
> How do prevent my session from timing out? I get this exception:
> Priming connection to java.nio.channels.SocketChannel[connected local=/
> WARN - Closing:
> Session Expired
>         at
>:406) at
>         at
> ERROR - from SendThread
> java.lang.NoSuchMethodError: org.apache.log4j.Logger.isTraceEnabled()Z
>         at
>         at
>         at
> Why would this happen and how can I prevent this from happening? How should
> the software react to this situation?:
> Avinash

Check out the new Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
Zookeeper-user mailing list

Reply via email to