Chanikag
Chanikag

Reputation: 1441

Zookeeper client node did not reconnect after session expired

I intercepted the connection between Zookeeper server and the client node using a custom TCP Monitor (Similar to TCPMon). I stopped the TCPMon and restarted it. When I restarted the TCPMon after the session expiration the client node is notified ("session has expired") but did not reconnect. How can I get it fixed?

Upvotes: 3

Views: 5387

Answers (1)

Randgalt
Randgalt

Reputation: 2956

Once you get session expired, you need to close the ZooKeeper handle and re-create it.

From The Programmer's Guide - "once a ZooKeeper object is closed or receives a fatal event (SESSION_EXPIRED and AUTH_FAILED), the ZooKeeper object becomes invalid"

Upvotes: 2

Related Questions