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 5A23E986D for ; Fri, 2 Mar 2012 02:47:35 +0000 (UTC) Received: (qmail 13522 invoked by uid 500); 2 Mar 2012 02:47:34 -0000 Delivered-To: apmail-zookeeper-user-archive@zookeeper.apache.org Received: (qmail 12931 invoked by uid 500); 2 Mar 2012 02:47:33 -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 12910 invoked by uid 500); 2 Mar 2012 02:47:33 -0000 Delivered-To: apmail-hadoop-zookeeper-user@hadoop.apache.org Received: (qmail 12891 invoked by uid 99); 2 Mar 2012 02:47:32 -0000 Received: from minotaur.apache.org (HELO minotaur.apache.org) (140.211.11.9) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 Mar 2012 02:47:32 +0000 Received: from localhost (HELO mail-iy0-f176.google.com) (127.0.0.1) (smtp-auth username camille, mechanism plain) by minotaur.apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 Mar 2012 02:47:32 +0000 Received: by iagw33 with SMTP id w33so2269735iag.35 for ; Thu, 01 Mar 2012 18:47:32 -0800 (PST) Received-SPF: pass (google.com: domain of camille@apache.org designates 10.50.168.99 as permitted sender) client-ip=10.50.168.99; Authentication-Results: mr.google.com; spf=pass (google.com: domain of camille@apache.org designates 10.50.168.99 as permitted sender) smtp.mail=camille@apache.org Received: from mr.google.com ([10.50.168.99]) by 10.50.168.99 with SMTP id zv3mr320510igb.21.1330656452005 (num_hops = 1); Thu, 01 Mar 2012 18:47:32 -0800 (PST) MIME-Version: 1.0 Received: by 10.50.168.99 with SMTP id zv3mr268156igb.21.1330656451989; Thu, 01 Mar 2012 18:47:31 -0800 (PST) Received: by 10.231.160.209 with HTTP; Thu, 1 Mar 2012 18:47:31 -0800 (PST) In-Reply-To: References: Date: Thu, 1 Mar 2012 21:47:31 -0500 Message-ID: Subject: Re: methods to figure out what causes an ephemeral node to be deleted From: Camille Fournier To: user@zookeeper.apache.org Cc: zookeeper-user@hadoop.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Running your transaction logs through the LogFormatter. You should see an explicit delete, or the close of the owning session. The LogFormatter is not awesome though... I have some better versions of it that I will throw up on GitHub in a bit and link if you're interested. On Thu, Mar 1, 2012 at 9:43 PM, Adam Rosien wrote: > I'm trying to track down the exact cause of an ephemeral node being > deleted. I know it could be either (a) the session where the node was > created has expired, or (b) some session, perhaps the same one that creat= ed > the node, explicitly deletes the node. Is there a good way to figure out, > client-side or server-side, the actual cause of a node deletion? > > Specifically, I have a log message like the following, and I want to know > "where" it came from: > > 2012-03-01 17:02:44 [main-SendThread(blah:2181)] [DEBUG] > [org.apache.zookeeper.ClientCnxn =A0 =A0 =A0 =A0 ] - Got WatchedEvent > state:SyncConnected type:NodeDeleted path:/blah/blah/blah for sessionid > 0x333a2e75199161b > > Also, is the referenced session id the session id of a watch on the delet= ed > node, or the session id of the session that deleted the node? I'm guessin= g > the former. > > .. Adam