Solved

Very complex data operation leads to HTTP timeout and does not complete..

Posted on 2008-10-04
5
273 Views
Last Modified: 2010-04-14
Hi I am using VB.net 2003 asp.net 1.1 doing web application on dedicated Windows 2003 server.

One thing in admin web app does very complex thing...

First gets list of all people in database and then needs to update them one at a time.  One field needs to be updated in every persons row - it is a point count and depending on how they answered a questionairre they get points added to their account.  So i have SP that selects all customers, then it checks them one by one and awards points...

The problem is that the web page times out HTTP timout does not finish.


I also have same exact problem when I pull list of all customers to send out email blast.
It gets all customers and compares them agains do not email list.  And then emails the person if not on the do not email list.  Problem is there are 100,000 people and it times out and does not email everyone.

Using  MS Sql 2005
VB.net 2003  asp.net
(calling sql sp's)

How can I make it not to time out?
0
Comment
Question by:hagoog
5 Comments
 
LVL 59

Accepted Solution

by:
Kevin Cross earned 200 total points
ID: 22642256
Try adding this to your web.config:
<system.web>
    <httpRuntime executionTimeout="1000"/>
    <!-- other configuration here -->
</system.web>

Open in new window

0
 
LVL 2

Assisted Solution

by:madivad2
madivad2 earned 100 total points
ID: 22642257
I played with this some time ago, and can't remember exactly where, but I believe in the web.config file under the "forms" tag you can set a timeout. If it is just the case your operation is taking too long, I think that should fix it.

This could also be an issue with the IIS server which can override the below setting. Try it and see how you go
<configuration>
 <system.web>
  ...
  <authentication mode="Forms">
   <forms name="MyForm"
          loginUrl="~.Login.aspx"
          protection="All"
          timeout="30" path="/" />
  </authentication>
 </system.web>
 ...
</configuration>

Open in new window

0
 
LVL 19

Assisted Solution

by:elimesika
elimesika earned 100 total points
ID: 22642272
HI

Try to enlarge the command time out connection parameter.

See VB code sample at
http://www.sqlservercentral.com/Forums/Topic492443-149-1.aspx
0
 
LVL 59

Assisted Solution

by:Kevin Cross
Kevin Cross earned 200 total points
ID: 22642341
If you don't have a SQL Server Central account, take a look at the CommandTimeout property of SqlClient.SqlCommand.

http://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqlcommand_members.aspx

You can set the CommandTimeout = 1000 to match the HTTP runtime timeout we set in Web.config.
0
 
LVL 26

Assisted Solution

by:Anurag Thakur
Anurag Thakur earned 100 total points
ID: 22642469
what kind of time out you are talking about (there are 3 kinds)
1. Web service timeout controlled by IIS
2. IIS thread execution timeoout
3. DB Command timeout

1. Can be controlled through timeout in the following (in seconds)
<sessionState timeout="20" />

2. Can be controlled by setting the executionTimeout (in seconds)
<httpRuntime executionTimeout="XXX" />

3. Can be controlled by setting the Command Timeout to 0 (means infinite)
0

Featured Post

ScreenConnect 6.0 Free Trial

At ScreenConnect, partner feedback doesn't fall on deaf ears. We collected partner suggestions off of their virtual wish list and transformed them into one game-changing release: ScreenConnect 6.0. Explore all of the extras and enhancements for yourself!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question