oh!...I got it.
I was using only zookeeper handle, and only one watcher object. And, this
watcher object is registered for different znodes changes. So, I need not
synchronize the process method.
Thanks a lot Benjamin & Dave,
Srikanth.
On Mon, Jul 19, 2010 at 3:46 PM, Benjamin Reed wrote:
> zo
zookeeper handles are not znodes. znodes refer to elements in the
zookeeper data tree. you do not need to synchronize the process method
when using the same Watcher object for different znodes. if you use the
same watcher for called to different ZooKeeper objects (i doubt you are
doing this) th
Thanks Dave & Ben.
So, ultimately I need to synchronize process() method, when the same Watcher
object is registered with different zookeeper handles (or Znodes). :)
On Mon, Jul 19, 2010 at 3:03 PM, Benjamin Reed wrote:
> yes, you (and dave) are correct. watches are invoked sequentially in orde
yes, you (and dave) are correct. watches are invoked sequentially in
order. the only time you can run into trouble is if you register the
same watcher object with different zookeeper handles since there is a
dispatch thread per zookeeper handle.
ben
On 07/19/2010 02:50 PM, Srikanth Bondalapat
Does this mean that, when I am processing one event, then the zookeeper
won't be firing another event. It does so only when the first event is
completely processed & returned by the callback object. Am I correct in my
interpretation??
Thanks & Regards,
Srikanth.
On Mon, Jul 19, 2010 at 2:40 PM, D
There is a single thread used to fire notification callbacks, your
callbacks will be called in order one at a time and you only need to
worry about synchronizing state with the rest of your code.
-Dave Wright
On Mon, Jul 19, 2010 at 5:37 PM, Srikanth Bondalapati:
wrote:
> Hi,
>
> I have a class