when using HttpWebRequest, HttpWebResponse, The webBrowser
class or pretty much anything relating to doing HTTP transactions there
is a limit on the number of connections you can have to a server. This
limit is defined by the HTTP RFC (no idea what number it is). This is
why with internet explorer you can only download 2 files from a server
at the same time.
Unfortunately with building an application you
might have 30 clients all requesting a component that calls out using
one of the HTTP classes.
<configuration>
<system.net>
<connectionManagement>
<clear/>
<add name = "www.mysite.com" maxconnection = "40" />
<add name = "*" maxconnection = "2" />
</connectionManagement>
</system.net>
</configuration>
The ConnectionManagement allows
you to override the builtin 2 connection limit. Here I have set it to a
max of 40 simultaneous connections to www.mysite.com and 2 to everywhere else. If your system
only accesses one address I would specify the address.
The
reason for specifying if you can is to limit what someone can do if
they can override the url that your HTTP client is using. This could
then techincally be used to perform a DOS against someone elses web
page.