?
Solved

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

Posted on 2008-10-04
5
Medium Priority
?
308 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 60

Accepted Solution

by:
Kevin Cross earned 800 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 400 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 400 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 60

Assisted Solution

by:Kevin Cross
Kevin Cross earned 800 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 400 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

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

I recently went through the process of creating a Calendar Control of events with the basis of using a database to keep track of the dates that are selectable, one requirement was to have the selected date pop-up in a simple lightbox.  At first this…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…
Suggested Courses

809 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