runzhiwang opened a new pull request #123:
URL: https://github.com/apache/incubator-ratis/pull/123


   ## What changes were proposed in this pull request?
   
   1. It's hard to finish write one 10M file and hundred 1M file in 100 
seconds, if the leader re-election happens when write, timeout will happens.
   
   2. `if (offset < writeSize)`  we can not throw exception. For example,  if 
leader finish write data with offset = 4096 and length = 4096, then writeSize 
become 8192, and 2 follower has not written the data with offset = 4096 and 
length = 4096, then start a leader re-election. So client will retry send the 
data with offset = 4096 and length = 4096, then offset < writeSize in leader. 
   If we throw exception, leader can not write successfully forever.
   
   ## What is the link to the Apache JIRA
   
   https://issues.apache.org/jira/browse/RATIS-904
   
   ## How was this patch tested?
   
   Existed 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.

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


Reply via email to