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 F233F17EB5 for ; Wed, 26 Aug 2015 12:36:04 +0000 (UTC) Received: (qmail 83094 invoked by uid 500); 26 Aug 2015 12:36:03 -0000 Delivered-To: apmail-zookeeper-user-archive@zookeeper.apache.org Received: (qmail 83039 invoked by uid 500); 26 Aug 2015 12:36:03 -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 83027 invoked by uid 99); 26 Aug 2015 12:36:03 -0000 Received: from Unknown (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Aug 2015 12:36:03 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id F1EAFC0250 for ; Wed, 26 Aug 2015 12:36:02 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.105 X-Spam-Level: X-Spam-Status: No, score=-0.105 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RP_MATCHES_RCVD=-0.006, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=yahoo.com Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id M74IKjzsrwp5 for ; Wed, 26 Aug 2015 12:35:54 +0000 (UTC) Received: from nm37-vm0.bullet.mail.bf1.yahoo.com (nm37-vm0.bullet.mail.bf1.yahoo.com [72.30.238.200]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTPS id B83D720865 for ; Wed, 26 Aug 2015 12:35:53 +0000 (UTC) Received: from [66.196.81.172] by nm37.bullet.mail.bf1.yahoo.com with NNFMP; 26 Aug 2015 12:35:47 -0000 Received: from [68.142.230.73] by tm18.bullet.mail.bf1.yahoo.com with NNFMP; 26 Aug 2015 12:35:47 -0000 Received: from [127.0.0.1] by smtp230.mail.bf1.yahoo.com with NNFMP; 26 Aug 2015 12:35:47 -0000 X-Yahoo-Newman-Id: 628597.22156.bm@smtp230.mail.bf1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: WbzAqWgVM1nTSHfrJTYySWOzuYoD0E_JmTmbiF81qLmScDr m511qNIiCAObhcI.uBgbVSc5LSHDVoUyE0bUMND2TEMEu7YzA6uUqEspGy8f ZvbOAHTIKLnqoB5jMx6yeiTFSIRtRnXXo7TE5wDgKpUiqqzbEEppivoX0ntP D9RwRrcqbhB5DOCF76fAO1JiO.weaTtd_AzuqlANBdhRrv_E00XaDKkm4m5X SXqt_5ojrYzqMuhPMf8d9WzbJGzaAKBQV0bOg4fjSUcE5la66NgVqNlCyiXe 0DrLB7hhXKWSdK.IAE.46vWbkewAvbM3aT2Hvfl_Eu_ib3VKBjgUflIdzp73 HP0jJlTLzFlVrWTj138s0U7CzgN1OgDPOV7sXNhmIkJbOqlRXa_0O_375wEN 5rGQs_QalgjneCIWcNmJyE6PMPIfOVhacbEnqfNdfhOYfOZ.iG4F47grISQ8 _Rk08QThitJqe_KFyxu93V09fv3WAC9zmFGbq3XM2e2lppD.unK8xNMuVyju AuLvDp28yygCZW.NCU7IpchAxeVU9.Sg- X-Yahoo-SMTP: HT5UJDeswBACWJPOeualxAa.da..S.fl Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2098\)) Subject: Re: Get_children after create From: Flavio Junqueira In-Reply-To: Date: Wed, 26 Aug 2015 13:35:45 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: <6146868A-0AE7-4678-AF8A-5EC97366CC78@yahoo.com> References: To: user@zookeeper.apache.org X-Mailer: Apple Mail (2.2098) Hi Robert, If it is the same client that created the znode, then yes, it does read = its own writes. A different client may not read it immediately because = we propagate updates agreed upon to the replicas asynchronously. You = could watch the parents for changes, though, and have the client being = notified when the newly created child becomes visible for that client. -Flavio > On 26 Aug 2015, at 11:08, Robert Rosolek = wrote: >=20 > To clarify more: in my program no-one is deleting this node in the > meantime. Also the state of the zookeeper session is Connected all the = time. >=20 > On Wed, Aug 26, 2015 at 10:03 AM, Robert Rosolek = > wrote: >=20 >> Hi, >>=20 >> Sorry if this question was asked here before, but I couldn't find the >> search functionality in the archives. >>=20 >> My question is the following: after create operation is successful, = am I >> guaranteed to >> see the new child when doing get_children on the parent? I have a = program, >> that seems to be breaking because it makes this assumption. Looking = at the >> lock recipe at >> = https://github.com/apache/zookeeper/blob/trunk/src/recipes/lock/src/java/o= rg/apache/zookeeper/recipes/lock/WriteLock.java, >> it seems this code does *not* make this assumption and simply keeps >> retrying in a tight loop until it finds the child. >>=20 >> Thank you, >> Robert >>=20