Return-Path: Delivered-To: apmail-hadoop-zookeeper-user-archive@minotaur.apache.org Received: (qmail 51492 invoked from network); 9 May 2009 19:38:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 9 May 2009 19:38:22 -0000 Received: (qmail 41306 invoked by uid 500); 9 May 2009 19:38:22 -0000 Delivered-To: apmail-hadoop-zookeeper-user-archive@hadoop.apache.org Received: (qmail 41219 invoked by uid 500); 9 May 2009 19:38:21 -0000 Mailing-List: contact zookeeper-user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: zookeeper-user@hadoop.apache.org Delivered-To: mailing list zookeeper-user@hadoop.apache.org Received: (qmail 41208 invoked by uid 99); 9 May 2009 19:38:21 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 09 May 2009 19:38:21 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [64.78.17.18] (HELO EXHUB018-3.exch018.msoutlookonline.net) (64.78.17.18) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 09 May 2009 19:38:12 +0000 Received: from EXVMBX018-1.exch018.msoutlookonline.net ([64.78.17.47]) by EXHUB018-3.exch018.msoutlookonline.net ([64.78.17.18]) with mapi; Sat, 9 May 2009 12:37:51 -0700 From: Scott Carey To: "zookeeper-user@hadoop.apache.org" Date: Sat, 9 May 2009 12:37:51 -0700 Subject: RE: NodeChildrenChanged WatchedEvent Thread-Topic: NodeChildrenChanged WatchedEvent Thread-Index: AcnQbdXU3rAIwmlZQZSdCmHky4XvvwAbjayi Message-ID: References: , In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org That is not the point. Its not about what you can or can't do, its how much code you have to write= to do it. And especially how much boilerplate, repeated handling of error= s and exceptions. The base ZK API is too low level for basic tasks and requires a lot of ugly= exception handling -- especially the synchronous API. Its all there for a= reason, but those reasons don't apply to every use case. What I am suggesting are higher level constructs that do these repeated mun= dane tasks for you to handle those use cases where the verbosity of the API= is a hinderance to quality and productivity.=20 ________________________________________ From: Ted Dunning [ted.dunning@gmail.com] Sent: Friday, May 08, 2009 11:16 PM To: zookeeper-user@hadoop.apache.org Subject: Re: NodeChildrenChanged WatchedEvent You can use the exists() call to get pretty much what you want. On Fri, May 8, 2009 at 7:01 PM, Scott Carey wrote= : > > On 5/8/09 2:15 PM, "Ted Dunning" wrote: > > > There is no gap in time if you put the new watch into the call that giv= es > > you the current version of the data. That is the point of having the > watch > > argument in all of the get* calls! > > > > There is a gap in time between when watch A triggers, and when the server > gets your next watch setting. From both the server and client point of > view, the watch "ends" when it fires, and there is a gap in time before t= he > next one begins. > Changes between those times must be inferred by the client. > >=