Return-Path: Delivered-To: apmail-hadoop-zookeeper-user-archive@minotaur.apache.org Received: (qmail 44022 invoked from network); 1 Oct 2009 07:00:07 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 1 Oct 2009 07:00:07 -0000 Received: (qmail 62137 invoked by uid 500); 1 Oct 2009 07:00:06 -0000 Delivered-To: apmail-hadoop-zookeeper-user-archive@hadoop.apache.org Received: (qmail 62045 invoked by uid 500); 1 Oct 2009 07:00:06 -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 62025 invoked by uid 99); 1 Oct 2009 07:00:06 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 01 Oct 2009 07:00:06 +0000 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: 216.145.54.173 is neither permitted nor denied by domain of phunt@apache.org) Received: from [216.145.54.173] (HELO mrout3.yahoo.com) (216.145.54.173) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 01 Oct 2009 06:59:54 +0000 Received: from [10.72.244.25] (snvvpn1-10-72-244-c25.hq.corp.yahoo.com [10.72.244.25]) by mrout3.yahoo.com (8.13.6/8.13.6/y.out) with ESMTP id n916vqUD093062; Wed, 30 Sep 2009 23:57:53 -0700 (PDT) Message-ID: <4AC452EF.5010405@apache.org> Date: Wed, 30 Sep 2009 23:57:51 -0700 From: Patrick Hunt User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: Stefan Groschupf CC: zookeeper-user@hadoop.apache.org, "zookeeper-dev@hadoop.apache.org" Subject: Re: feedback zkclient References: <4AC3D75F.4080300@apache.org> In-Reply-To: <4AC3D75F.4080300@apache.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org I started looking a bit more closely at the source, some questions: 1) I tried generating the javadocs (see my fork of the project on github if you want my changes to build.xml for this) but it looks like there's pretty much no javadoc. Some information, particularly on semantics of user-exposed operations would be useful (esp re my earlier README comment - some high level document describing the benefits, etc... of the library) If I'm your proto-typical "lazy developer" (which I am :-) ), I'm really expecting some helpful docs to get me bootstrapped. 2) what purpose does ZkEventThread serve? 3) there's definitely an issue in the retryUntilConnected logic that you need to address let's say you call zkclient.create, and the connection to the server is lost while the request is in flight. At this point ConnectionLoss is thrown on the client side, however you (client) have no information on whether the server has made the change or not. The retry method's while loop will re-run the create (after reconnect), and the result seen by the caller (user code) could be either OK or may be NODEEXISTS exception, there's no way to know which. Mahadev is working on ZOOKEEPER-22 which will address this issue, but that's a future version, not today. 4) when I saw that you had separated zkclient and zkconnection I thought "ah, this is interesting" however when I saw the implementation I was confused: a) what purpose does this separation serve? b) I thought it was to allow multiple zkclients to share a single connection, however looking at zkclient.close, it closes the underlying connection. 5) there's a lot of wrapping of exceptions, looks like this is done in order to make them unchecked. Is this wise? How much "simpler" does it really make things? Esp things like interrupted exception? As you mentioned, one of your intents is to simplify things, but perhaps too simple? Some short, clear examples of usage would be helpful here to compare/contrast, I took a very quick look at some of the tests but that didn't help much. Is there a test(s) in particular that I should look at to see how zkclient is used, and the benefits incurred? Regards, Patrick Patrick Hunt wrote: > Hi Stefan, two suggestions off the bat: > > 1) fill in something in the README, doesn't have to be final or > polished, but give some insight into the what/why/how/where/goals/etc... > to get things moving quickly for reviewers & new users. > > 2) you should really discuss on the dev list. It's up to you to include > user, but apache discourages use of user for development discussion > (plus you'll pickup more developer insight there) > > Patrick > > Stefan Groschupf wrote: >> Hi Zookeeper developer, >> it would be great if you guys could give us some feedback about our >> project zkclient. >> http://github.com/joa23/zkclient >> The main idea is making the life of lazy developers that only want >> minimal zk functionality much easier. >> >> We have a functionality like zkclient mock making testing easy and >> fast without running a real zkserver, simple call back interfaces for >> the different event types, reconnecting handling in case of timeout etc. >> >> We feel we come closer to a release so it would be great if some >> experts could have a look and give us some feedback. >> Thanks, >> Stefan >> >> >> >> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >> Hadoop training and consulting >> http://www.scaleunlimited.com >> http://www.101tec.com >> >> >>