Return-Path: X-Original-To: apmail-curator-user-archive@minotaur.apache.org Delivered-To: apmail-curator-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E99041065B for ; Fri, 30 May 2014 19:35:50 +0000 (UTC) Received: (qmail 28537 invoked by uid 500); 30 May 2014 19:35:50 -0000 Delivered-To: apmail-curator-user-archive@curator.apache.org Received: (qmail 28491 invoked by uid 500); 30 May 2014 19:35:50 -0000 Mailing-List: contact user-help@curator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@curator.apache.org Delivered-To: mailing list user@curator.apache.org Received: (qmail 28481 invoked by uid 99); 30 May 2014 19:35:50 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 May 2014 19:35:50 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of kasha@cloudera.com designates 209.85.192.48 as permitted sender) Received: from [209.85.192.48] (HELO mail-qg0-f48.google.com) (209.85.192.48) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 May 2014 19:35:47 +0000 Received: by mail-qg0-f48.google.com with SMTP id i50so6657370qgf.7 for ; Fri, 30 May 2014 12:35:24 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=GDKHCH1Fb+iMNU0mFmT2OyTiUBXHpV6WQdB5CheMWqQ=; b=dHJUItlKHeS9oPmJ/Z4N39C+wkbz5zIbqVj0bQ9muEagaBnsiZ9HnDjjC1QnwQAvQE 7rqkvATb7myFPZMa3xNXSzf7YGYg66EtWMePvftX3fQkiEg+Ohgc+DpvJryX7DKJWthK AKng+h6zUapgFqmBeE9XgUHMRgobIg7lMlUwkfNkxjSW7NGFvFhJy4qGRT+VAi8FfdFh z55zND3HAkk/mZ+zoaDULOAx/aTvboHZWTJ5rv95YUkqEuTuun3dDP8tqcw1GPL6mkbF tjHUmh+xqyHhzvZXdW3KKTensGWGMurn9ExLrdaFXjzgBJGEwlPUngvPZnQxxO93IDbl ekTw== X-Gm-Message-State: ALoCoQl/R/Nm0HafYDVutvDbVSpejUOnVrRR6TdaWyPHYzJKKW9cl3O0L7u+JEm0M3ggdoh448YQ MIME-Version: 1.0 X-Received: by 10.229.171.193 with SMTP id i1mr24495066qcz.15.1401478523819; Fri, 30 May 2014 12:35:23 -0700 (PDT) Received: by 10.96.180.103 with HTTP; Fri, 30 May 2014 12:35:23 -0700 (PDT) In-Reply-To: References: Date: Fri, 30 May 2014 12:35:23 -0700 Message-ID: Subject: Re: CuratorFramework: multiple auths From: Karthik Kambatla To: Jordan Zimmerman Cc: user@curator.apache.org Content-Type: multipart/alternative; boundary=001a11c3066892c6ea04faa325f4 X-Virus-Checked: Checked by ClamAV on apache.org --001a11c3066892c6ea04faa325f4 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Thanks Jordan. Will file a JIRA, and see if I can post a patch as well. Is there a way to be notified when the underlying ZooKeeper instance is updated? On Fri, May 30, 2014 at 12:31 PM, Jordan Zimmerman < jordan@jordanzimmerman.com> wrote: > It looks like this is a limitation of Curator. Multiple auth support woul= d > need to be added. Please open an issue in the Curator Jira. > > For now, you=E2=80=99ll need to get the underlying ZooKeeper instance dir= ectly and > add it: > > curator.getZookeeperClient().getZooKeeper().addAuth(=E2=80=A6) > > Note, however, that if there is a connection problem Curator will allocat= e > a new ZooKeeper instance and you=E2=80=99d have to add the auth to that a= s well. > > -Jordan > > > From: Karthik Kambatla kasha@cloudera.com > Reply: user@curator.apache.org user@curator.apache.org > Date: May 30, 2014 at 12:07:23 PM > To: user@curator.apache.org user@curator.apache.org > Subject: CuratorFramework: multiple auths > > Hi > > I am very new to Curator, but have used ZK before. Firstly, let me thank > you for putting Curator together - it makes talking to Zookeeper very eas= y. > > I have one of those noob questions and will greatly appreciate any help. > > For my usecase, I need multiple auths - multiple schemes - for my > connection. In the vanilla ZK world, I would call Zookeeper#addAuthInfo f= or > each of my schemes. How do I achieve the same using Curator? > > CuratorFrameworkFactory.Builder#authorization seems to allow adding a > single auth. I googled around but couldn't find much information. I was > considering calling > CuratorFramework#getZookeeperClient#getZookeeper()#addAuthInfo, but wasn'= t > sure if these auths would be preserved across disconnects/ session > timeouts. > > Is there a way to either add multiple auths or get notified if the > underlying client changes? > > Thanks again for all your help, > > Karthik > > --001a11c3066892c6ea04faa325f4 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Thanks Jordan. Will file a JIRA, and see if I can post a p= atch as well.=C2=A0

Is there a way to be notified when t= he underlying ZooKeeper instance is updated?=C2=A0


On Fri, May 30, 2014 at 12:31 PM, Jordan= Zimmerman <jordan@jordanzimmerman.com> wrote:
<= blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px= #ccc solid;padding-left:1ex">
It loo= ks like this is a limitation of Curator. Multiple auth support would need t= o be added. Please open an issue in the Curator Jira.

For now, you=E2=80=99ll need to get the underlying ZooKeeper instance direc= tly and add it:

curator.getZookeeperClient().g= etZooKeeper().addAuth(=E2=80=A6)

=
Note, however, that if there is a connection problem Curator will allocate = a new ZooKeeper instance and you=E2=80=99d have to add the auth to that as = well.

-Jordan


From:=C2=A0Karthik Kambatla kasha@cloudera.com
= Reply:=C2=A0user@curator.apache.org user@curator.apache.org<= br> Date:=C2=A0May 30, 2014 at 12:07:23 PMTo:=C2=A0user@curator.apache.org user@curator.apache.org Subject:=C2=A0 CuratorFramework: multiple auths=

Hi=C2=A0

I am very new to Curator, but have used ZK before. Firstly, let me thank you for putting Curator together - it makes talking to Zookeeper very easy.=C2=A0

I have one of those noob questions and will greatly appreciate any help.

For my usecase, I need multiple auths - multiple schemes - for my connection. In the vanilla ZK world, I would call Zookeeper#addAuthInfo for each of my schemes. How do I achieve the same using Curator?

CuratorFrameworkFactory.Builder#authorization seems to allow adding a single auth. I googled around but couldn't find much information. I was considering calling CuratorFramework#getZookeeperClient#getZookeeper()#addAuthInfo, but wasn't sure if these auths would be preserved across disconnects/ session timeouts.=C2=A0

Is there a way to either add multiple auths or get notified if the underlying client changes?

Thanks again for all your help,

Karthik

--001a11c3066892c6ea04faa325f4--