zookeeper-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Wangpei (Peter)" <peter.wang...@huawei.com>
Subject Re: when the zookeeper Expired ,may I have to rebuild the watch on a znode?
Date Mon, 04 Jun 2012 04:01:11 GMT
No. setting watcher is binds to session, so it will not triggered anymore.
you have to set the watcher again on the new session, do it yourself.
My way is writing a reconnect watcher decorator, this class add a connection watcher and it
rebuild watcher.
A connection wrapper should simplify the code.

-----邮件原件-----
发件人: iamct [mailto:qddxct@gmail.com] 
发送时间: 2012年6月4日 10:42
收件人: zookeeper-user@hadoop.apache.org
主题: when the zookeeper Expired ,may I have to rebuild the watch on a znode?

I had seted a watch on one znode.When the zookeeper session expired,I create a new zookeeper
session.
The watch I had seted is effective ?
I can/t find a answer in FAQ.
How can i do?

--
View this message in context: http://zookeeper-user.578899.n2.nabble.com/when-the-zookeeper-Expired-may-I-have-to-rebuild-the-watch-on-a-znode-tp7577513.html
Sent from the zookeeper-user mailing list archive at Nabble.com.
Mime
View raw message