NIO2 async threading
Alan Bateman
Alan.Bateman at Sun.COM
Fri Jun 13 09:55:11 PDT 2008
Rob Butler wrote:
> Hello,
>
> I was wondering how threading would work for asynchronous channels? Since callbacks are invoked to perform all reading/writing that work will always take place in threads controlled by the async provider, right? Is there any standard way to control how many threads are in use? To set the thread type (daemon, non-daemon)? To set the thread names?
>
> Rob
>
>
>
>
[ moving to nio-discuss (if okay with you) as there are folks interested
in this area that don't subscribe to the -dev mailing list ]
The class to check out is AsynchronousChannelGroup. There you will see
how to configure the ThreadFactory, number of threads, etc. If you see
anything missing or have comments please let us know.
-Alan.
More information about the nio-discuss
mailing list