views:

106

answers:

1

hey guys,

I've got a very simple Windows Form app that hits an IIS 7 site about 2000 times in the space of a few seconds (using threads).

When I run that app on the server itself, using either localhost or the ip address, everything is totally fine.

However, when I run the app on my dev box, using the ip address, I get an error from the "GetResponse" method:

The operation has timed out

The App can definitely connect to the site, because it consistently either starts throwing the timeout error after 10 or so hits (no more than 11), or it throws the timeout error immediately.

What's going on?

It's hitting IIS 7 on a Windows Server 2008 VM (external box), Windows Firewall is OFF.

My App is running locally on my dev box as the admin.

cheers

+2  A: 

I believe the default thread pool size for IIS is about 10 threads. You're overloading that single server.

Are you doing performance testing? Do you expect that many requests, that fast, in production?

Dave Swersky
thanks for the quick response dave. But why would it not throw this error when I run the app locally on the server? Do you think that maybe it's just because it releasing each thread quicker, so it seems like it's handling more threads?
andy
localhost totally skips the network stack. It's not even apples to apples.
Josh Einstein
There's no latency when running local, so the socket opens and closes within milliseconds.
Dave Swersky
@josh: right, thanks Josh. Does it skip the stack even when using the IP address?
andy
@Dave: cool, thanks dave. So essentially, in my app, I should monitor when it reaches 10, and then wait until responses are complete before making any further requests?
andy