Connectiontimeout, commandtimeout, and executiontimeout

Source: Internet
Author: User
Connectiontimeout

Obtain the time that is waiting before the connection is terminated and an error is generated.
The wait time (in seconds) for the connection to open ). The default value is 15 seconds. 

connect timeout or keywords in the connection string. "XML: Space =" preserve "style =" background-color: # FFFF E1; font-family: 'segoe UI ', verdana, Arial; font-size: 13px; line-Height: normal; "> by using the connect timeout or connection timeout keyword. You can set the timeout value for the connection.

The value 0 indicates no limit.ConnectionstringThe value 0 should be avoided; otherwise, the connection will wait for an indefinite period of time. 

 

Commandtimeout

Obtain or set the wait time before terminating the Command Execution Attempt and generating an error.

The waiting time (in seconds ). The default value is 30 seconds. 

 

The value 0 indicates that there is no limit (the attempt to execute the command will wait for an indefinite period ).

 Description

commandtimeout property will be ignored during Asynchronous Method CILS such as begi Nexecutereader . "XML: Space =" preserve "> in Asynchronous Method call (such as beginexecutereader ), commandtimeout attribute is ignored.

commandtimeout has no effect when the command is executed against a context connection (A sqlconnection opened with "context connection = true" in the connection string ). "XML: Space =" preserve "> when you connect to the context (use the" context connection =" True "when the sqlconnection command is opened, commandtimeout does not work.

description

This attribute is the cumulative timeout for all network reads during command execution or processing results. after the first row is returned, the timeout may still occur, but only the network read time, not the user processing time.

 

Httpruntimesection. executiontimeout

 

 Obtain or set the allowed execution time of the request.

 ExecutiontimeoutIndicates the maximum number of seconds that a request can be executed before it is automatically disabled by ASP. NET. The default value is 90 seconds.

 <Httpruntime Maxrequestlength="102400"Executiontimeout="720"/>

 

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.