Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
Zookeeper >> mail # user >> redundant watches


Copy link to this message
-
Re: redundant watches
The only one I can confirm specifically is (b). There is no way to cancel a
watch. We really needed that feature in our code base that uses Zookeeper,
so we added a layer in our code base that achieves that result. And you're
right, I've seen a couple of Jira cases related to cancelling watches but
nothing has been officially merged that I'm aware of.

On Wed, Jan 18, 2012 at 4:50 PM, Ted Dunning <[EMAIL PROTECTED]> wrote:

> I just had a question from an engineer regarding watches.  I realized in
> answering that I am not 100% sure that my answer is correct and would like
> some confirmation.
>
> The scenario is when redundant watches are set on a znode.  The questions
> are:
>
> a) is there any adverse impact to redundant watches in which the same
> Watcher object is set as watcher for the same operations on the same node.
>  (proposed answer: I don't think so.  I think all watches will be triggered
> in sequence just like non-redundant watches).
>
> b) is there any way to determine whether a watch is already set or a list
> of all watches already set?  (proposed answer:  I don't think so.  There
> certainly isn't any obvious way in the API to do this)
>
> c) is there any way to cancel a watch.  (proposed answer: I don't think so.
>  There has been recent action on this, but nothing final yet)
>
> d) is there a way to create a watch such that there is exactly one watch
> for the session on a particular znode?  (proposed answer: I don't see any
> way)
>
> Can somebody confirm or deny these answers?
>
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB