netty/netty — pull request #789 by trustin (2012-12-04 10:31:21+00:00)
Title: Allow a user to trigger the epoll bug workaround

This commit adds rebuildSelector(s) method to Boss, BossPool, Worker, and WorkerPool. A user can call rebuildSelector(s) method to initiate the workaround for the infamous epoll 100% CPU bug in Linux based on his or her observations rather than potentially incorrect automatic initiation of the workaround.

Previously, setInterestOps() were executed by a caller thread, which made re-registration of SelectionKeys unsafe. This commit also ensures setInterestOps() is always executed by an I/O thread. With this change, we don't need NioProviderMetadata anymore.