From user-return-11869-archive-asf-public=cust-asf.ponee.io@zookeeper.apache.org Wed Mar 13 12:43:47 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id EBA5118064A for ; Wed, 13 Mar 2019 13:43:46 +0100 (CET) Received: (qmail 6825 invoked by uid 500); 13 Mar 2019 12:43:45 -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 6793 invoked by uid 99); 13 Mar 2019 12:43:44 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Mar 2019 12:43:44 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 6A37AC609E for ; Wed, 13 Mar 2019 12:43:44 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.201 X-Spam-Level: X-Spam-Status: No, score=-0.201 tagged_above=-999 required=6.31 tests=[DKIMWL_WL_MED=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=googlemail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id i7sahvV_wurU for ; Wed, 13 Mar 2019 12:43:43 +0000 (UTC) Received: from mail-qk1-f174.google.com (mail-qk1-f174.google.com [209.85.222.174]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 6421761186 for ; Wed, 13 Mar 2019 12:37:28 +0000 (UTC) Received: by mail-qk1-f174.google.com with SMTP id n6so948443qkf.1 for ; Wed, 13 Mar 2019 05:37:28 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to :content-transfer-encoding; bh=Pouf9L+eS8dY8gMMPlUPifh4v6tV7pkckC4jIIU3Vdw=; b=nyM0FylvfwnGPTXWubXLrY1r7e9Ok1OP6GUzCOxNjNAQnqPVly0yFEk53zugjLUlD9 T8NxxFBgUN7suhKvfB2HfV6kgalVBs6g6CDBsrI55k4ryjwwVdQgr1pcol2q9iaDL/qh hlgkop6zE7FKni4xHhYxYUl9Pt0h+YL7KF1riSiVwAVG5nkaRPqEe6oLbHyVUhoPLd8s um6nJLnX5opt5JPKxYG9r8sJpEa45oK3npGT+CjZ171jb/HUEMmpRSk1nVOP/1+r2cX5 p6phtAGUwV3prQf7+Gor1bijyE4KlgSrUy0lfKNDxKh8Z8UAXh8zD+z2M6LndKXmdIjO TL4g== X-Gm-Message-State: APjAAAX8pjcyBWHx863PkTMf0XN0+YrDgLyDgphlRo49BgZeOYP9RyTo f4BJZ1myoPQOfqkwcdLJrlKf+StoqM8zdpCeC9IuScyu X-Google-Smtp-Source: APXvYqxweSIvZrvk2i7Iie5aIgw+CVeq/5otUIHy4xGf64yuZlGbSVenqhwWT/Lxq/qYl9tK466sU6dwnw+LXGYWCUc= X-Received: by 2002:a37:bdc6:: with SMTP id n189mr32842528qkf.50.1552480647823; Wed, 13 Mar 2019 05:37:27 -0700 (PDT) MIME-Version: 1.0 From: Robin Wolters Date: Wed, 13 Mar 2019 13:37:17 +0100 Message-ID: Subject: Zookeeper syncing with Curator To: user@zookeeper.apache.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello, I use Zookeeper in a cluster setup and some of my read operations need to be consistent, meaning I have to make sure that a read always reflects all previous writes (which might be performed on another zookeeper server and has not reached all other instances). The idea is to force a sync before those reads to make them =E2=80=9Cconsistent=E2=80=9D reads with: client.sync().forPath(path) For this, I have these questions left: 1. Do you need to manually await the callback of sync before reading, or is the next read operation queued until the sync is complete? 2. Which amount of data is transferred between the nodes in this kind of manual sync? a) Does it always transfer and process data from the master server even if the syncing node is up-to-date on this path - or only for those nodes that are really out of sync (i.e. sync only possible deltas)? b) Does a sync on the path also force the parent nodes to sync? c) Does a sync on the path also force all child nodes to sync? d) How would one manually sync the complete data (as the regular sync does) of a node? Is client.sync().forPath("/") the way to do this? Anyone experiences with this? Best regards, Robin