Return-Path: X-Original-To: apmail-zookeeper-user-archive@www.apache.org Delivered-To: apmail-zookeeper-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C7741DDB6 for ; Tue, 26 Jun 2012 15:23:30 +0000 (UTC) Received: (qmail 82177 invoked by uid 500); 26 Jun 2012 15:23:29 -0000 Delivered-To: apmail-zookeeper-user-archive@zookeeper.apache.org Received: (qmail 82153 invoked by uid 500); 26 Jun 2012 15:23:29 -0000 Mailing-List: contact user-help@zookeeper.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@zookeeper.apache.org Delivered-To: mailing list user@zookeeper.apache.org Received: (qmail 82145 invoked by uid 99); 26 Jun 2012 15:23:29 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Jun 2012 15:23:28 +0000 X-ASF-Spam-Status: No, hits=0.7 required=5.0 tests=RCVD_IN_DNSWL_NONE,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: local policy) Received: from [98.139.52.223] (HELO nm26.bullet.mail.ac4.yahoo.com) (98.139.52.223) by apache.org (qpsmtpd/0.29) with SMTP; Tue, 26 Jun 2012 15:23:20 +0000 Received: from [98.139.52.190] by nm26.bullet.mail.ac4.yahoo.com with NNFMP; 26 Jun 2012 15:22:58 -0000 Received: from [98.139.52.177] by tm3.bullet.mail.ac4.yahoo.com with NNFMP; 26 Jun 2012 15:22:58 -0000 Received: from [127.0.0.1] by omp1060.mail.ac4.yahoo.com with NNFMP; 26 Jun 2012 15:22:58 -0000 X-Yahoo-Newman-Id: 958344.36180.bm@omp1060.mail.ac4.yahoo.com Received: (qmail 7673 invoked from network); 26 Jun 2012 15:22:58 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1340724178; bh=RC2akgLwOVujLN5jt22aN8qz/EEY6/RtzfY8L6tiSo4=; h=X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Received:References:In-Reply-To:Mime-Version:Content-Transfer-Encoding:Content-Type:Message-Id:Cc:X-Mailer:From:Subject:Date:To; b=174z40TnZLVNDc9BbPKtG6XA+fZAz+OGsWJikILFu/Ot+dGn5qA9XrxgZoZ8XirIH2nYFpiM/42+egnjFC1OIBuK/WbDgguyXY+LgclAqzYCN7sxS9or2HTxMJjNBbY9qw2R0D32v3P5mJHsotIgZoNHq31gucSu3gON1Mkbwr0= X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: _nWNZicVM1njretAIrqqgmy_0Hm.kKS9Tf2pOlokx1HXtQ_ a13TFgoyBVuyBM.VtKRPsoeLQVANu9vEa5T9jIlGxzXeOA4rILFHfkkSv718 UwqQIy4BV4LPDhplpB4wC0t3mv6dUx0Uz52C3uDgk9eKtoeErd4HzM2350sc NFEikv9.ezUgTY.hFfONKSEleu6.HNEJvZl2SzbIMiLNprHr5nyo5Z_TgNZJ S4csVLoIEOOHKrY5jA0yKXPqJlkGPr5szSUe2jDe8t6cAtylVYYtKdNHfo6r QBijELUkGpqO2VcmvjjJ3aHJ1xdLLQMuGDwxRNwpT4_KTtFeuNwnQYOhxYn9 Z1.Pz5sf95ZruBmDSCOt.kpQyle1.s4630smzZqBi922KX2BCD4WPzFz9NiR PjqFdNLjWJtzsBVSnRVGPeNMO X-Yahoo-SMTP: nOqelraswBBh1gusd6U.BxG0ops- Received: from [192.168.0.197] (jordan@76.103.249.200 with xymcookie) by smtp126-mob.biz.mail.ac4.yahoo.com with SMTP; 26 Jun 2012 08:22:58 -0700 PDT References: In-Reply-To: Mime-Version: 1.0 (1.0) Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Message-Id: <90BD1922-B75D-409E-9DC6-B7E1F95FCBED@jordanzimmerman.com> Cc: ZooKeeper mailing list X-Mailer: iPhone Mail (9B206) From: Jordan Zimmerman Subject: Re: Dealing with an expired session Date: Tue, 26 Jun 2012 08:22:55 -0700 To: "" X-Virus-Checked: Checked by ClamAV on apache.org All watchers will get called with session expiration, disconnect, etc.=20 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Jordan Zimmerman On Jun 26, 2012, at 7:51 AM, "David Nickerson" wrote: > In my locking implementation, if a thread wants to wait for a lock, it wil= l > create a watcher object, set a watch on the lock before it, and wait on th= e > watcher. When the watch gets triggered, the watcher notifies any threads > that are waiting on it. >=20 > If the session expires, I would like to wake up all of the threads that ar= e > waiting for a lock. To my understanding, only the default watcher receives= > a notification that the session has expired. If this is the case, then I > need to maintain a list somewhere of all of the watchers that threads are > waiting on so that I can notify them all. >=20 > Does this sound correct?