Details
-
Bug
-
Status: Open
-
Critical
-
Resolution: Unresolved
-
3.5.0
-
None
-
None
-
Windows 8.1, Windows 2012, Visual Studio 2012
Description
Hi All,
Under WIndows 8.1 and 2012, using the ZooKeeper C client 3.5.0, when running my ZooKeeper client, just after the ZooKeeper Client is connecting with the ZooKeeper server, the ZooKeeper server is generating a “caught end of stream” exception and deciding my is ZooKeeper client is not responsive: Zookeeper.c::check_events, line 2298: ESTALE. (see log below).
This problem systematically appears if the ZooKeeper DLL is NOT link statically with the Visual Studio debug version of the threaded runtime library.
This is reproducible 10/10
In clear, Windows ZooKeeper C client will works only if you link your ZooKeeper DLL with the switch "/MTd" (see VS Studio->Project->Configuration properties->C/C++>Code generation>runtime library)
Thanks
Bruno
========================================
ZooKeeper server log
========================================
2015-02-06 13:19:57,552 [myid:vgcclustermgr] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:31000:NIOServerCnxnFactory@197] - Accepted socket connection from /10.1.200.237:63499
2015-02-06 13:19:57,553 [myid:vgcclustermgr] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:31000:ZooKeeperServer@868] - Client attempting to establish new session at /10.1.200.237:63499
2015-02-06 13:19:57,554 [myid:vgcclustermgr] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:31000:NIOServerCnxnFactory@197] - Accepted socket connection from /10.1.200.237:63500
2015-02-06 13:19:57,554 [myid:vgcclustermgr] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:31000:ZooKeeperServer@868] - Client attempting to establish new session at /10.1.200.237:63500
2015-02-06 13:19:57,555 [myid:vgcclustermgr] - INFO [SyncThread:0:ZooKeeperServer@617] - Established session 0x14b5bfcba7b0409 with negotiated timeout 80000 for client /10.1.200.237:63499
2015-02-06 13:19:57,555 [myid:vgcclustermgr] - WARN [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:31000:NIOServerCnxn@357] - caught end of stream exception
EndOfStreamException: Unable to read additional data from client sessionid 0x14b5bfcba7b0409, likely client has closed socket
at org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:228)
at org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:208)
at java.lang.Thread.run(Thread.java:744)
2015-02-06 13:19:57,555 [myid:vgcclustermgr] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:31000:NIOServerCnxn@1007] - Closed socket connection for client /10.1.200.237:63499 which had sessionid 0x14b5bfcba7b0409
2015-02-06 13:19:57,559 [myid:vgcclustermgr] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:31000:NIOServerCnxnFactory@197] - Accepted socket connection from /10.1.200.237:63501