Solved

maxconnection for .NET applications

Posted on 2011-03-17
2
846 Views
Last Modified: 2013-11-27
i have a potential problem with a .NET (2.0) web application that calls a web service on another server. the call can be spawned by every client page request, and i have encountered a "deadlock" error in the event log a few times, MS recommended increasing the value of "maxconnection" for such applications.

i was browsing a question about where can you change the value of "maxconnection" parameter, and the answer was to do in machine.config, using this section:


<system.net>
  <connectionManagement>
   <add address="*" maxconnection="10"/>
  </connectionManagement>
 </system.net>

my questions regarding that:

1) does it have to be in machine.config? can I create it for one specific app, using its web.config?

2) how do i  know (programmaticaly) that .NET is actually using the value i set?

3) MS declares that you can add multiple maxconnection, example:
   <add address="*" maxconnection="2"/>
   <add address="http://10.0.0.0" maxconnection="12"/>

in this case would there be a way for me to know that .NET is actually using the value i set for that specific address?


0
Comment
Question by:structuredweb
2 Comments
 
LVL 28

Accepted Solution

by:
strickdd earned 250 total points
ID: 35164565
Yes, web.configs are inherited from the highest level down to the current level. The precedence starts in the machine.config and the machine's web.config then to the website's root web.config and finally the web.config if the folder your code it running in. This means if you set it in a web.config for the website it will only affect that website.

As far as testing and verifying, that would probably take some network sniffing tools. You may also want to consider setting the value to 0 or 1 and load testing and compare that to a load test of the value being 100. That should give you an idea when you see the response times. Other than that, trust in microsoft.

To test which address you're pointing at, you can record incoming connections to the address you specify.
0
 
LVL 1

Author Closing Comment

by:structuredweb
ID: 35165375
no specific answer to a programatic interface, but maybe there isn't ..
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now