runzhiwang edited a comment on pull request #299:
URL: https://github.com/apache/incubator-ratis/pull/299#issuecomment-734020368


   @szetszwo Thanks the great work, the improvement is awesome.  But now 
transferTo only work on client, and it did not work on primary.  
   
   1. when primary store data to disk, the flow is: socket -> kernel space -> 
user space (DirectByteBuffer) -> kernel space -> disk
   2. when primary send data to peer, the flow is: socket -> kernel space -> 
user space (DirectByteBuffer same to the previous) -> kernel space -> socket.  
   
   And I think the ideal flow as follows, because we do not need to read the 
data in user space, but I'm not sure whether can we achieve it.
   
   1. when primary store data to disk, the flow is: socket -> kernel space -> 
disk
   2. when primary send data to peer, the flow is: socket (or disk) -> kernel 
space -> socket
   
   


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

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


Reply via email to