 |
| .NET Framework 2.0 For discussion of the Microsoft .NET Framework 2.0. |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the .NET Framework 2.0 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|

October 30th, 2006, 07:59 PM
|
|
Registered User
|
|
Join Date: Oct 2006
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Asp .Net 2.0 request/response timeout problem
Hi,
I am working on an application, where am collecting all the inputs from the user in web form, based on the inputs, form a query to the database (running on different server) and show the output as response.
The problem is , database query is taking a lot of time ( approx 2min).
By that time , the request times out and nothing is displaed as output.
How to set the timeout for request ?
Thanks,
Vijay
|
|

November 6th, 2006, 04:09 AM
|
|
Registered User
|
|
Join Date: Nov 2006
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hi,
Try setting timeout property in Web.config if you are using sessionState.
<sessionState mode="StateServer" stateConnectionString="tcpip=127.0.0.1:55455" sqlConnectionString="data source=127.0.0.1;user id=sa;password='' cookieless="false" timeout="200"/>
Regards,
Chandrak
|
|

November 25th, 2006, 01:48 PM
|
|
Authorized User
|
|
Join Date: Sep 2006
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hi Bhavsac , U have mentioned about session time out .That is different from connection out.
VijayT , U can use connection.timeout property to solve this problem.
connection.timeout=300
DO this after opening connection
|
|

November 25th, 2006, 02:41 PM
|
|
Registered User
|
|
Join Date: Oct 2006
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hi Rama,
Thanks for your reply.
Unfortunately, I tried that but it did not solve the problem.
I found out that the problem was because I was using Atlas components (updtaePanel ) as a container.That precisely times out in 90 sec.
Thoug I could find the origin of the problem, I am still clueless how to resolve it.I tried various things with "UpdatePanel" setting, but nothing works.
|
|

February 5th, 2007, 10:11 AM
|
|
Registered User
|
|
Join Date: Feb 2007
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
there is another option it is: CommandTimeout
it means how long single SQL comand can take to run.
--CommandTimeout how long single SQL command can take to run
System.Data.SqlClient.SqlCommand cmd;
cmd.CommandTimeout = 200;
--ConnectionTimeout How long may take to open connection
System.Data.SqlClient.SqlConnection con;
con.ConnectionTimeout = 200;
tadas @ mohawkideas.com
|
|

February 5th, 2007, 01:26 PM
|
|
Registered User
|
|
Join Date: Oct 2006
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hi ,
Yes, i tried Coomand timeout, but it did not work for me.
Actually, another dimension to the problem is - I am using "Atlas" (AJAX for Asp .Net 2.0).Is that something to do ith "Atlas" ? If yes, how can I set the timeout for it ?
Thanks,
Vijay
|
|
 |