You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Shevek (JIRA)" <ji...@apache.org> on 2013/03/30 00:41:15 UTC

[jira] [Created] (ZOOKEEPER-1680) Cannot connect with a given sessionId - it is discarded

Shevek created ZOOKEEPER-1680:
---------------------------------

             Summary: Cannot connect with a given sessionId - it is discarded
                 Key: ZOOKEEPER-1680
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1680
             Project: ZooKeeper
          Issue Type: Bug
            Reporter: Shevek


While the API permits construction of a ZooKeeper client object with a given sessionId, the sessionId can never be used:

ClientCnxn line 850: long sessId = (seenRwServerBefore) ? sessionId : 0;

The only person who sets seenRwServerBefore is onConnected().

Therefore, it appears that passing a sessionId into a ZooKeeper constructor has no effect, as the ClientCnxn has never seen an RW server before, so it discards it anyway.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira