Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / July 2006

Tip: Looking for answers? Try searching our database.

ThreadPool queue size

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
yofnik@comcast.net - 21 Jul 2006 17:32 GMT
Hello,
Does anyone know if there is a way to check the size of the ThreadPool
wait queue should the number of available threads become busy?

Thanks
Michael Nemtsev - 21 Jul 2006 18:32 GMT
Hello Yofnik,

Didn't quite understand u.
U mean ThreadPool.GetAvailableThreads method?

Y> Hello,
Y> Does anyone know if there is a way to check the size of the
Y> ThreadPool
Y> wait queue should the number of available threads become busy?
Y> Thanks
Y>
---
WBR,
Michael  Nemtsev :: blog: http://spaces.msn.com/laflour

"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche
yofnik@comcast.net - 21 Jul 2006 22:26 GMT
No, I mean when GetAvailableThreads returns 0 - is there a way to find
out how many tasks are waiting to access a thread.

For example, say my application gets bombarded with requests - each of
which is handled in its own ThreadPool thread. If the requests are
coming in faster than the ThreadPool delegate can execute, eventually
GetAvailableThreads will be 0. Once this happens, is there a way to
find out how many requests are waiting for a ThreadPool thread to
become available ?

> Hello Yofnik,
>
[quoted text clipped - 13 lines]
> "At times one remains faithful to a cause only because its opponents do not
> cease to be insipid." (c) Friedrich Nietzsche
William Stacey [MVP] - 24 Jul 2006 02:46 GMT
No direct way.  You could wrap it and increment a counter in the
queueworkitem() and decrement in the callback helper wrapper.

Signature

William Stacey [MVP]

| No, I mean when GetAvailableThreads returns 0 - is there a way to find
| out how many tasks are waiting to access a thread.
[quoted text clipped - 23 lines]
| > "At times one remains faithful to a cause only because its opponents do not
| > cease to be insipid." (c) Friedrich Nietzsche

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.