Call the resolution of the WebService timeout problem __web

Source: Internet
Author: User
to call the resolution of the WebService timeout problem

I. Server-side Settings

1, web.config configuration,<system.web></system.web> inside Add:

2, expand the proxy class time-out limit, the default is 90 seconds
Yourwebservice Yws = new Yourwebservice ();
Yws. Timeout = 1200000; 20 minutes.

3. IIS Properties-Web site Connection Timeout time 1200 seconds

two. Client Settings

1, modify the app.config file, add the following code:

Request execution timeout is 600 seconds (default is 110 seconds)

2, set the Timeout properties of WEB Services

Timeout, in milliseconds, for the synchronization call to the XML Web services. The default is 100000 milliseconds.

LywSqCommon.sqsdData.GetData GetData = new LywSqCommon.sqsdData.GetData ();//getdata to class name

getdata.timeout=700000;//Unit is milliseconds

Indicates the time, in milliseconds, that an XML Web services client waits for the synchronization of an XML Web services request to complete.

Tip: If you set the Timeout property to Timeout.infinite, it indicates that the request has no time-out. Even if the XML Web Services client can set the Timeout property to No timeout, the WEB server can still cause the request to timeout on the server side.

The system will use the smallest of the above two settings as the length of time the operation timed out.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.