Sebastian Pölsterl wrote:
> Hi!
>
> I'm trying to write a Downloader that downloads in that case 3 files.
> Downloading is done in a thread while the main thread should print the
> status.
>
> Unfortunatly, if I have 3 files that should be downloaded the last Thread
> never terminates. Whereas, I download 1 or 2 files everything works fine.
>
> I tested it with ThreadPools and Async Threads, but it's always the same
> result.
>
> I can't see any sense in that behavior. I would be more than happy if
> someboy could help me.
According to the HTTP RFC, a client must not maintain more than
2 open connections to the server. WebClient is respecting this
restriction.
You can raise the limit by addding this to your app.confg:
<configuration>
<system.net>
<connectionManagement>
<add name = "*" maxconnection = "10" />
</connectionManagement>
</system.net>
</configuration>
or with
System.Net.ServicePointManager.DefaultConnectionLimit = 10;
Robert
_______________________________________________
Mono-list maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-list