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 6077519852 for ; Mon, 4 Apr 2016 16:29:43 +0000 (UTC) Received: (qmail 72147 invoked by uid 500); 4 Apr 2016 16:29:42 -0000 Delivered-To: apmail-zookeeper-user-archive@zookeeper.apache.org Received: (qmail 72084 invoked by uid 500); 4 Apr 2016 16:29:42 -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 72072 invoked by uid 99); 4 Apr 2016 16:29:42 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 04 Apr 2016 16:29:42 +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 D4334C0222 for ; Mon, 4 Apr 2016 16:29:41 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.003 X-Spam-Level: X-Spam-Status: No, score=-0.003 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (1024-bit key) header.d=junipernetworks.onmicrosoft.com Received: from mx2-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id fRdG-WQ59jzc for ; Mon, 4 Apr 2016 16:29:39 +0000 (UTC) Received: from na01-bl2-obe.outbound.protection.outlook.com (mail-bl2on0139.outbound.protection.outlook.com [65.55.169.139]) by mx2-lw-eu.apache.org (ASF Mail Server at mx2-lw-eu.apache.org) with ESMTPS id E969C5F65B for ; Mon, 4 Apr 2016 16:29:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=junipernetworks.onmicrosoft.com; s=selector1-juniper-net; h=From:To:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=dwNB8fehXGFWHMxQRfhi9rxW22cjoXN5YhmQaJLXKg8=; b=VXtK3O3PRK91SeU85zg0bjPF+zpgrfn1sVSSW88zsSvKQSnkCgDjk/SeoEh56yRAuNPX82z+rLTAcpll0sRfDtoFh1U2eGMvtmPgqydZV0hhU28lwnixPvepl0hgo/qpNA11A+WkJZDOeXDjx53LlWi5at9KKxlujL4dfedgj9Q= Received: from CY1PR0501MB1321.namprd05.prod.outlook.com (10.160.226.139) by CY1PR0501MB1323.namprd05.prod.outlook.com (10.160.226.140) with Microsoft SMTP Server (TLS) id 15.1.447.15; Mon, 4 Apr 2016 16:29:31 +0000 Received: from CY1PR0501MB1321.namprd05.prod.outlook.com ([10.160.226.139]) by CY1PR0501MB1321.namprd05.prod.outlook.com ([10.160.226.139]) with mapi id 15.01.0447.027; Mon, 4 Apr 2016 16:29:31 +0000 From: Pramod Srinivasan To: "user@zookeeper.apache.org" Subject: Re: automatic update of server set at the client on reconfig Thread-Topic: automatic update of server set at the client on reconfig Thread-Index: AQHRi6icSK19hCpDuEuCuH8sHkExNZ90m3uAgAACNJQ= Date: Mon, 4 Apr 2016 16:29:31 +0000 Message-ID: References: , In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: zookeeper.apache.org; dkim=none (message not signed) header.d=none;zookeeper.apache.org; dmarc=none action=none header.from=juniper.net; x-originating-ip: [132.245.23.149] x-ms-office365-filtering-correlation-id: 76b419bf-357f-46a7-dd5a-08d35ca64cd8 x-microsoft-exchange-diagnostics: 1;CY1PR0501MB1323;5:bBZLZ3ztqC+rXB4qrnzl8LU8uGGFlGJi/VCYUUXZAo5it7ytmngIZUaOLiJhsHFRxvO2gvPpaUzZfjFSzNhkbGqhCs2f7uYgPPNO9xWdHXYkQu5ieapp1L8o7nRrbytFTAtyllbLTz3OjvHPNKH1jw==;24:buoYkXKl5z7tfYerWStYMHIAsd33e7HCh3IS8KJ8UunC+Z7Mr2fQQJN6F+hYEyIHY6wrpGT+zGE1tv9fd0kaJr1cGAIOVV68hBC0ZXLF/2U= x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:CY1PR0501MB1323; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(138986009662008); x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046);SRVR:CY1PR0501MB1323;BCL:0;PCL:0;RULEID:;SRVR:CY1PR0501MB1323; x-forefront-prvs: 0902222726 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(979002)(6009001)(377454003)(51914003)(24454002)(164054003)(33656002)(2501003)(5002640100001)(87936001)(15650500001)(66066001)(3900700001)(5004730100002)(10400500002)(5008740100001)(189998001)(19580405001)(77096005)(110136002)(107886002)(3660700001)(2950100001)(2900100001)(19580395003)(15975445007)(74316001)(2351001)(99286002)(450100001)(3280700002)(76176999)(122556002)(11100500001)(50986999)(86362001)(54356999)(106116001)(3846002)(1220700001)(2906002)(81166005)(1096002)(92566002)(102836003)(6116002)(586003)(76576001)(969003)(989001)(999001)(1009001)(1019001);DIR:OUT;SFP:1102;SCL:1;SRVR:CY1PR0501MB1323;H:CY1PR0501MB1321.namprd05.prod.outlook.com;FPR:;SPF:None;MLV:ovrnspm;PTR:InfoNoRecords;LANG:en; spamdiagnosticoutput: 1:23 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: juniper.net X-MS-Exchange-CrossTenant-originalarrivaltime: 04 Apr 2016 16:29:31.2041 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: bea78b3c-4cdb-4130-854a-1d193232e5f4 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY1PR0501MB1323 Thanks for the info Alex! I will check the code. ________________________________________ From: Alexander Shraer Sent: Thursday, March 31, 2016 10:43 PM To: user@zookeeper.apache.org Subject: Re: automatic update of server set at the client on reconfig Hi, Please see update_addrs() function of the C client, and the following link: https://zookeeper.apache.org/doc/trunk/zookeeperReconfig.html#ch_reconfig_r= ebalancing It could be automated further (e.g., ZOOKEEPER-2016 ) but there hasn't been enough progress on this. Any contributions very appreciated! Cheers, Alex On Thu, Mar 31, 2016 at 4:54 PM, Pramod Srinivasan wrote: > Hello Folks > > I am playing with reconfig to grow the zookeeper cluster dynamically, wha= t > I observed is that the C client library (don=B9t know about the java clie= nt) > does not automatically reconfigure to the new server set after reconfig. > So if I go from Zookeeper server set [a, b, c] -> [a] -> [a, d, f] -> [d, > f, g], the client who was connected to server [a, b, c] will loose > connectivity to zookeeper and the session will close once we reach [d, f, > g]. If my application monitors the server config changes and feeds the > client library with the new server set using zoo_set_servers, the session > continues to be in connected state. Is this observations correct? > > Any reason why the C client library should not automatically reconfigure > itself with the server set by monitoring the zookeeper config path? > > Thanks, > Pramod > >