Idle connections keep threads on epollWait()
NettyUser5325
subhirn3 at yahoo.de
Wed Jan 26 14:00:11 EST 2011
Hi. Thanks for the quick answer.
I did some testing using the HexDumpProxy, and made the following
observations.
When limiting the number of threads by passing the proper limit as a
constructor argument to NioClientSocketChannelFactory and
NioServerSocketChannelFactory, the program works all fine. It keeps the
maximum number of threads on epollWait() as long as there are more open
connections than the thread limit.
However, I would like to dynamically set the thread limit during runtime,
which these classes do not allow me to do. So I tried to use the
java.util.concurrent.ThreadPoolExecutor class to do the limiting, and
creating the channel factories with a very high number. But this does not
seem to be feasible because the channel factories do not return the threads
for open connections, and the program does not get a thread to handle any
new connections anymore.
Is there any way to achieve a dynamic thread limiting in Netty?
Is it possible to specify an extra thread pool for threads that just manage
idle connections (and thereby limiting the number of threads on
epollWait())?
Is there a way to change this behavior that the channel factories always use
the maximum number of threads to do epollWait() on idle connections?
Thanks
--
View this message in context: http://netty-forums-and-mailing-lists.685743.n2.nabble.com/Idle-connections-keep-threads-on-epollWait-tp5962446p5963802.html
Sent from the Netty User Group mailing list archive at Nabble.com.
More information about the netty-users
mailing list