I am using Async delegates to make many RPC calls (each of which will take a
max of a couple seconds). This seemed acceptable since the threads aren't
really doing much on the local machine (the remote machines are doing all
the work).

Don't Async delegates actually use the thread pool? Doesn't this mean I'm
limited to 25 calls at a time?

Can I increase the size of the thread pool in my process?
Can I force the async delegates to use new threads instead of from the
thread pool?

Is there a better method for making many RPC calls?

-Joel

Re: ThreadPool limitation by Mattias

Mattias
Tue Jul 08 18:05:29 CDT 2003

Joel,

>Don't Async delegates actually use the thread pool?

Yes they do.


>Doesn't this mean I'm limited to 25 calls at a time?

Per procesor, yes, if you use the default.


>Can I increase the size of the thread pool in my process?

Yes, using the ICorThreadpool COM API.

http://staff.develop.com/woodring/dotnet/#tpcontrol

You could also use a custom thread pool

http://staff.develop.com/woodring/dotnet/#threadpool


>Can I force the async delegates to use new threads instead of from the
>thread pool?

No. Can't you explicitly create a new thread instead (if you really
want more than 25)?



Mattias

--
Mattias Sjögren [MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/
Please reply only to the newsgroup.