merlimat opened a new pull request #1321: Avoid contention on netty channel 
   With profiler, I have seen there can be heavy contention between BK threads 
and Netty IO thread due the the checking for channel write condition that was 
recently added for monitoring purpose. 
   The problem relies in that there is one BK thread that is doing the 
`writeAndFlush()` on the PCBC and getting the `ChannelFuture`, adding a 
listener to the future. 
   The write operation, though, is completed in the Netty IO thread and the 
promise gets also triggered from that thread. So, there is contention between 
current thread adding the listener and the IO threads completing the promise. 
   If we add the listener before doing the write on channel, we can avoid the 
contention. Another option could be to do the write from the Netty IO thread as 

This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:

With regards,
Apache Git Services

Reply via email to