You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Camille Fournier (JIRA)" <ji...@apache.org> on 2010/08/12 18:06:16 UTC

[jira] Created: (ZOOKEEPER-844) handle auth failure in java client

handle auth failure in java client
----------------------------------

                 Key: ZOOKEEPER-844
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
             Project: Zookeeper
          Issue Type: Improvement
          Components: java client
    Affects Versions: 3.3.1
            Reporter: Camille Fournier


ClientCnxn.java currently has the following code:
  if (replyHdr.getXid() == -4) {
                // -2 is the xid for AuthPacket
                // TODO: process AuthPacket here
                if (LOG.isDebugEnabled()) {
                    LOG.debug("Got auth sessionid:0x"
                            + Long.toHexString(sessionId));
                }
                return;
            }

Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


RE: [jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Fournier, Camille F. [Tech]" <Ca...@gs.com>.
Hi everyone,
Can someone explain what I should do for this? I have a patch for both 3.4 and 3.3, and I think the 3.3 patch caused issues in the automated patch applier. What do I need to do to submit both of these patches to the different branches? 

Thanks,
Camille

-----Original Message-----
From: Camille Fournier (JIRA) [mailto:jira@apache.org] 
Sent: Thursday, September 16, 2010 2:25 PM
To: zookeeper-dev@hadoop.apache.org
Subject: [jira] Updated: (ZOOKEEPER-844) handle auth failure in java client


     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Camille Fournier updated ZOOKEEPER-844:
---------------------------------------

    Attachment:     (was: ZOOKEEPER332-844)

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Camille Fournier (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Camille Fournier updated ZOOKEEPER-844:
---------------------------------------

    Attachment:     (was: ZOOKEEPER332-844)

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Camille Fournier (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Camille Fournier updated ZOOKEEPER-844:
---------------------------------------

    Fix Version/s: 3.3.2

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Improvement
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12910264#action_12910264 ] 

Patrick Hunt commented on ZOOKEEPER-844:
----------------------------------------

IIRC qabot will apply the most recent patch, it only knows about trunk though (no branches).

The easiest way to address is to attach the patch for br33 first, then attach the patch for trunk. Pretty hacky but it works ok for me.

The other option is to just attach both patches and state in a comment the problem, ask a committer to review it manually instead of waiting on qabot.

Thanks!

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Giridharan Kesavan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Giridharan Kesavan updated ZOOKEEPER-844:
-----------------------------------------

    Status: Open  (was: Patch Available)

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Giridharan Kesavan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Giridharan Kesavan updated ZOOKEEPER-844:
-----------------------------------------

    Status: Patch Available  (was: Open)

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Giridharan Kesavan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Giridharan Kesavan updated ZOOKEEPER-844:
-----------------------------------------

    Status: Open  (was: Patch Available)

submitting to hudson 

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Improvement
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Patrick Hunt updated ZOOKEEPER-844:
-----------------------------------

      Resolution: Fixed
    Hadoop Flags: [Reviewed]
          Status: Resolved  (was: Patch Available)

Committed to trunk/3.3. Thanks Camille!

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12909635#action_12909635 ] 

Hadoop QA commented on ZOOKEEPER-844:
-------------------------------------

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12453719/ZOOKEEPER332-844
  against trunk revision 997192.

    +1 @author.  The patch does not contain any @author tags.

    +1 tests included.  The patch appears to include 3 new or modified tests.

    -1 patch.  The patch command could not apply the patch.

Console output: http://hudson.zones.apache.org/hudson/job/Zookeeper-Patch-h7.grid.sp2.yahoo.net/112/console

This message is automatically generated.

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Camille Fournier (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Camille Fournier updated ZOOKEEPER-844:
---------------------------------------

    Attachment: ZOOKEEPER332-844

Patch for ZooKeeper 3.3.1 branch

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Improvement
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Patrick Hunt updated ZOOKEEPER-844:
-----------------------------------

    Status: Open  (was: Patch Available)

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Patrick Hunt updated ZOOKEEPER-844:
-----------------------------------

           Status: Patch Available  (was: Open)
         Assignee: Camille Fournier
    Fix Version/s: 3.4.0

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Improvement
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Patrick Hunt updated ZOOKEEPER-844:
-----------------------------------

    Issue Type: Bug  (was: Improvement)

This is really a bug, not an improvement.

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Patrick Hunt updated ZOOKEEPER-844:
-----------------------------------

    Status: Patch Available  (was: Open)

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Camille Fournier (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Camille Fournier updated ZOOKEEPER-844:
---------------------------------------

    Attachment: ZOOKEEPER-844.patch

Patch to fix this bug, please review. I looked at the C client and I believe this is the same basic way auth failed is handled in that code. Thanks.

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Improvement
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>         Attachments: ZOOKEEPER-844.patch
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Camille Fournier (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Camille Fournier updated ZOOKEEPER-844:
---------------------------------------

    Attachment: ZOOKEEPER-844.patch

patch to HEAD

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Camille Fournier (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Camille Fournier updated ZOOKEEPER-844:
---------------------------------------

    Attachment: ZOOKEEPER332-844

First the 3.3.2 patch...

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Giridharan Kesavan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Giridharan Kesavan updated ZOOKEEPER-844:
-----------------------------------------

    Status: Patch Available  (was: Open)

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Improvement
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Hudson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12918879#action_12918879 ] 

Hudson commented on ZOOKEEPER-844:
----------------------------------

Integrated in ZooKeeper-trunk #959 (See [https://hudson.apache.org/hudson/job/ZooKeeper-trunk/959/])
    ZOOKEEPER-844. handle auth failure in java client


> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Camille Fournier (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Camille Fournier updated ZOOKEEPER-844:
---------------------------------------

    Attachment:     (was: ZOOKEEPER-844.patch)

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-844) handle auth failure in java client

Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-844?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12918566#action_12918566 ] 

Patrick Hunt commented on ZOOKEEPER-844:
----------------------------------------

+1 looks good to me. Thanks Camille!

> handle auth failure in java client
> ----------------------------------
>
>                 Key: ZOOKEEPER-844
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-844
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: java client
>    Affects Versions: 3.3.1
>            Reporter: Camille Fournier
>            Assignee: Camille Fournier
>             Fix For: 3.3.2, 3.4.0
>
>         Attachments: ZOOKEEPER-844.patch, ZOOKEEPER332-844
>
>
> ClientCnxn.java currently has the following code:
>   if (replyHdr.getXid() == -4) {
>                 // -2 is the xid for AuthPacket
>                 // TODO: process AuthPacket here
>                 if (LOG.isDebugEnabled()) {
>                     LOG.debug("Got auth sessionid:0x"
>                             + Long.toHexString(sessionId));
>                 }
>                 return;
>             }
> Auth failures appear to cause the server to disconnect but the client never gets a proper state change or notification that auth has failed, which makes handling this scenario very difficult as it causes the client to go into a loop of sending bad auth, getting disconnected, trying to reconnect, sending bad auth again, over and over. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.