I have a net.tcp service hosted under IIS which is being hit concurrently by 300 clients. After doing a lot of configuration (throttling, maxconnections etc) I show that I have a thread pool problem and requests are not served quickly enough, because thread
pool creates new threads every half second. There is no error. My problem is that my clients are not served quickly enough. I configured the thread pool using SetMinThreads but nothing (I also configured SetMaxThreads accordingly). Then I discovered that there
is a .NET 3.5 bug and I installed the corresponding fix (http://support.microsoft.com/kb/976898). Now the behaviour I get is the following...
When the 300 clients hit the server, the server opens concurrently 300 threads (I see more than 300 threads for w3wp process in task manager) and clients are served very fast. If after this there are 300 more concurrent clients, they are being
served by reusing the previous threads. Excellent!!!
However, if I let the server idle for about 10 seconds, the threads are released! w3wp threads in the task manager drop to around 25. If after this again 300 clients hit the server thread pool starts again to create threads slowly (one every half second)!
Why is that?
Running Windows 7 x64, Quad Core, 8 GB RAM
View Complete Post