How to increase # of HttpWebRequest made from WCF Web Services RRS feed

  • Question

  • Hi,


    I built a WCF Web services application (Win 2003 SP2 using VS 2005) that groups together several underlying web services.  The application I built provides the security and entitlements layer for web services that provide data,  this is done so that they can be accessed from outside our corporate network.


    So each call to my WCF application requires a call to an underlying web services. 


    Now during my performance testing phase I noticed that the number of requests being made to the backend web services is about 20 - max.   So if I have a 100 users making requests constantly - 80 are being queued in my WCF app server and 20 requests are being sent to the backend server.  I need to increase the number from 20 to at least a 100.


    So far I have made the following changes:


    In machine.config I added:


    Code Snippet
       <add address="*" maxconnection="2000"/>   <!-- *** Yes I know 2000 is high  but please ignore for now ***  -->
       <socket alwaysUseCompletionPortsForAccept="true" alwaysUseCompletionPortsForConnect="true"/>



    Browsing through many forums I see that this should be the fix to what I am seeing but it is not.I see in my code that the service point manager does in fact see the # of connections as 2000 and it should be taking effect but it doesnt work.


    So I wrote a quick ASP.NET v2.077 aspx page that makes a static request to the backend web service and writes the response in the html markup.   This works as it should.  200 users making requests to this page shows 200 requests on the backend web service.


    Now I assumed WCF might be the culprit so I wrote a WCF app that does the same thing. A single service that makes a static request to a backend web service.  Here I notice that 200 users making requests to the WCF service only generates about 20 requests to the backend.


    Requests to the backend web service are made using the HttpWebRequest and HttpWebResponse class.



    Is there a configuration piece I have missed??  I am looking at MSDN docs for





    Is this right?  Has anyone experienced this problem?? Please help Smile

    Tuesday, February 12, 2008 8:30 PM