Re: ThreadPool VS Thread

Tech-Archive recommends: Fix windows errors by optimizing your registry



On Wed, 28 Feb 2007 01:32:56 -0500, William Stacey [C# MVP] wrote:

This seems to work and many code I see does this (and I have done it).
However, I also wonder if this is just a bug waiting to happen. Is it just
the fact we are getting lucky and the iocp thead is always keep alive during
our usage (as we normally get a reply pretty fast under normal conditions)?
Or does the os do some fixup behind the covers that allows the async call to
remain thread agnostic because we started it on an IOCP thread? I would
love to know the answer.

I've done quite a lot of reading over the last few days regarding this
issue and it seems that nobody really knows the answer to that. There is an
awful lot of confusion when it comes to async socket operations. Everybody
seems to aggree that async socket calls should be prefered over sync calls
for scalabilty reasons but nobody seems to know how to actually use async
socket calls. And the documentation doesn't help either. I find this quite
astonishing as socket programming is as the heart of many applications
nowdays, not really a very specific, niche programming technique. How come
Microsoft doesn't come up with a white paper about these issues? For now,
i'll keep doing what everybody else does and hope for the best but i don't
feel particularly good about it either.
.



Relevant Pages

  • Re: ThreadPool VS Thread
    ... | issue and it seems that nobody really knows the answer to that. ... | awful lot of confusion when it comes to async socket operations. ... And the documentation doesn't help either. ... | nowdays, not really a very specific, niche programming technique. ...
    (microsoft.public.dotnet.general)
  • Re: ThreadPool VS Thread
    ... | issue and it seems that nobody really knows the answer to that. ... | awful lot of confusion when it comes to async socket operations. ... And the documentation doesn't help either. ... | nowdays, not really a very specific, niche programming technique. ...
    (microsoft.public.dotnet.general)