On Fri, Oct 17, 2014 at 5:39 PM, Monish Gandhi <monishgandhi@xxxxxxxxx
> Thanks Simone ! Also could you please confirm that the when socket connects
> and acceptor thread accepts the same, when does it go back to accepting new
> connections. Is it after registering ServerSocketChannel with selector and
> submitting to Selector queue (_changes.offer in SelectorManager.submit()). I
> assume the state in this SelectorManager.submit() in such case would be
> "PROCESS" and hence should come out immediately.
When a connection is accepted, it is passed to
SelectorManager.accept(), that returns immediately so that a new
connection may be accepted.
The number of acceptors can be configured, and those will all compete
to accept connections (although only one will succeed).
> Is it ever possible that if my selectors are busy then my acceptor thread
> won't go back to accepting new connections?
No, it's not possible.