mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Emmanuel Lecharny <elecha...@gmail.com>
Subject [MINA 3.0] Single vs Multiple Selector
Date Mon, 22 Feb 2010 08:35:39 GMT
Hi guys,

in MINA 2.0, the system is based on IoProcessor containing a selector. 
The default configuration is to instanciate nb CPU +1 IoProcessors, that 
means the same number of Selector.

In his book on NIO, Ron Hitchens says to "resist the urge to use 
multiple selectors. Performing readiness selection on large number of 
channels is not expensive". Also we should consider that on Windows, a 
new Selector is created under the hood each time we have attached 1024 
socket to the old one, so the work is already done for us.

Julien has drafted a system using a Strategy class to define the number 
of selectors to use. This is a good approach, IMO.

However, at some point, we need to experiment what are the pros and cons 
of each startegy on each system, otherwise we are just pulling ideas out 
of the back of our anatomy, without any elements to justify our choices, 
something we suffered from in MINA 2.0.

The questio is : how do we test that? Wouldn't be convenient to create 
some tests project in the sandbox for such experiment ?

Emmanuel L├ęcharny

View raw message