fanyang89 opened a new pull request, #2116:
URL: https://github.com/apache/zookeeper/pull/2116

   This patch fixes a problem in the ZooKeeper client that causes requests to 
be sent out of order.
   
   When multiple threads attempt to submit requests, it's possible for a 
request from a thread that acquired its xid earlier to be inserted after a 
request from a thread that acquired its xid later in the submission queue, 
which causes a ZRUNTIMEINCONSISTENCY error.
   
   This patch acquires a lock before get_xid() and releases it after request 
submission.
   
   Another way to fix this is to assign the xid during request submission, but 
this would disrupt the order of caller submissions: the request submitted first 
does not necessarily have a smaller xid.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to