omalley opened a new pull request, #4527:
URL: https://github.com/apache/hadoop/pull/4527

   ### Description of PR
   
   I modified the RPC Connection class to use a single thread that does the 
writes to the socket instead of a thread factory. (It already has a different 
thread that does the reads.) Java’s concurrency library has a SynchronousQueue 
that will simplify hand offs from the calling thread to the rpc sending thread.
   
   As a result, we’ll end up with:
   * Exactly 1 sending thread per an RPC connection.
   * If the calling thread is interrupted before the socket write, it will be 
skipped instead of sending it anyways.
   * If the calling thread is interrupted during the socket write, the write 
will finish.
   * RPC requests will be written to the socket in the order received.
   
   ### How was this patch tested?
   
   Added a unit test.
   
   
   


-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to