zookeeper-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hanno Schlichting <ha...@hannosch.eu>
Subject Re: Testing expired sessions bug?
Date Wed, 22 Aug 2012 20:09:41 GMT
On Wed, Aug 22, 2012 at 8:54 PM, Hanno Schlichting <hanno@hannosch.eu> wrote:
> Note how there's no ZooTrace entries in here and no "Session 0x... is
> valid..." message as logged in ZooKeeperServer.revalidateSession.
> Reading the server code it looks like the checkPasswd check fails in
> reopenSession. But I have no idea why that would suddenly happen in
> some of the cases.

Apparently it's the session password as memorized in the C binding.

This is the output of doing essentially:

handle = zookeeper.init(...)
print 'Client id %s' % repr(zookeeper.client_id(handle))

Run number: 9
test_bad_session_expire (kazoo.tests.test_client.TestConnection) ...
Client id: (0L, '')
Client id: (88189511064027136L,
'\x7fIFM\xa0\x96\x9e\xbc\xf5\xadZ\x0e\xe9wd\xfe')

Run number: 10
test_bad_session_expire (kazoo.tests.test_client.TestConnection) ...
Client id: (0L, '')
Client id: (88189511508623360L, '\xff')

In all good cases we see proper passwords of 16 bytes. In the failure
case we just get '\xff'.

Hanno

Mime
View raw message