JacksonYao287 opened a new pull request #497:
URL: https://github.com/apache/ratis/pull/497


   ## What changes were proposed in this pull request?
   
   since we have [RATIS-1399](https://github.com/apache/ratis/pull/496), each 
`notify` of all the log senders will be executed in parallel , default using 
ForkJoinPool ,which has a fixed num of threads in thread pool (default the same 
as the num of cpu core)
   
   in GrpcLogAppender.java,  `synchronized` is used for two purposes:
   
   1 protect `wait()`
   
   2 protect variables like  `pendingRequests`, `pending` , etc.
   
   this patch add a separate RWLock for the second case , and keep 
`synchronized` only for wait and notify, thus any slow IO option will not block 
notify.
   
   ## What is the link to the Apache JIRA
   
   https://issues.apache.org/jira/browse/RATIS-1400
   
   ## How was this patch tested?
   
   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]


Reply via email to