Back to list
Views:   80.1K
Replies:  2
Archived
How to overcome web service timeout?
I have a web application which sends some message to a web service. The web service then pass on the message to data access service (which is a window service). The data access service connects to database and get the data from different tables and the work on the data and send the custom response to web service which then pass on the response to ui application.
The problem i am facing is web service gets time out while windows service is still doing the data manipulation and creating the response. how can a keep the web service alive for that particular request without getting time out.
Rahul Sabharwal, Sep 21, 2010
Reply 1
Service Timeout value can be set in three places

A. To increase the Timeout property of the Web service proxy.
        
        MyServiceRef serviceRef= new MyServiceRef();
        obj.Timeout = -1; // -1 for infinite or + any positive value in milliseconds
                
B. To Increase Increase timeout value in httpruntime tag in web/app.config of ASP.NET

        <httpRuntime executionTimeout="<<milliseconds>>" />

C. To increase timeout value in httpruntime tag in web-config of Web Services
project.

adviced locaiton is cliend side, don't play with at serverside. it might effect other clients.


Thanks,
Hops this helps
Srihari Chinna, Oct 23, 2010
Reply 2
There are actually 2 ways to configure time out:

--- On the server side, you can set/change this time out in web.config See: <httpRuntimeexecutionTimeout="..."/>
and
--- On the client side, you can set Timeout property in class called SoapHttpClientProtocol
Rahul Kansara, Oct 01, 2010
Stay Inspired!
Join other developers and designers who have already signed up for our mailing list.
Terms     Privacy     Licensing       EULA       Sitemap      
© Data & Object Factory, LLC.
Made with    in Austin, Texas