Thread pooling in AIO?

Nord, James JNord at nds.com
Thu Dec 18 03:53:29 PST 2008


> > I think a fixed pool is probably the wrong choice for async 
> I/O - it 
> > would make more sense to use a cached pool which can scale up on 
> > demand, with a sensible timeout for non-core threads.
> If the server is completely event driven then a fixed thread 
> pool can work very well.
> 
> One word of warning is one needs to be careful to avoid idle 
> timeout/keep alive on Windows due to the way that I/O works 
> on that platform. I/O operations are tied in the kernel to 
> the initiating thread; if a thread terminates (because it is 
> idle) then outstanding I/O operations that it has initiated 
> may be aborted.


So your using AlertableIO[1] and not IOCompletion[2] ports then?
Doesn't this have inherant scalability issues as you can only proccess
on the same thread?
It also means you can have some intersting thread management issues...

[1]http://msdn.microsoft.com/en-us/library/aa363772(VS.85).aspx
[2]http://msdn.microsoft.com/en-us/library/aa365198(VS.85).aspx

Regards,

	/James

*********************************************************************************************************
This e-mail is confidential, the property of NDS Ltd and intended for the addressee only.  Any dissemination, copying or distribution of this message or any attachments by anyone other than the intended recipient is strictly prohibited.  If you have received this message in error, please immediately notify the postmaster at nds.com and destroy the original message.  Messages sent to and from NDS may be monitored.  NDS cannot guarantee any message delivery method is secure or error-free.  Information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses.  We do not accept responsibility for any errors or omissions in this message and/or attachment that arise as a result of transmission.  You should carry out your own virus checks before opening any attachment.  Any views or opinions presented are solely those of the author and do not necessarily represent those of NDS.

To protect the environment please do not print this e-mail unless necessary.

NDS Limited Registered office: One Heathrow Boulevard, 286 Bath Road, West Drayton, Middlesex, UB7 0DQ, United Kingdom. A company registered in England and Wales  Registered no. 3080780   VAT no. GB 603 8808 40-00
**********************************************************************************************************



More information about the nio-discuss mailing list