kezhuw commented on PR #2047:
URL: https://github.com/apache/zookeeper/pull/2047#issuecomment-2994764322

   > Why not just invoke selector.select method after cleanup? After 
selector.select, the canceled sockKey will be removed from selector.keys, and 
fd will be released.
   
   This sounds sensible and is a one for all solution. Currently, `cleanup` 
could not close socket until next `selector.select`. By do additional `select`, 
socket could be closed instantly.
   
   @lchqlchq What do you think on this ? I think we could add 
`selector.selectNow` right after `sockKey.cancel` in `cleanup.


-- 
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: notifications-unsubscr...@zookeeper.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to