Solved

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

Posted on 2008-10-04
5
271 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

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

A quick way to get a menu to work on our website, is using the Menu control and assign it to a web.sitemap using SiteMapDataSource. Example of web.sitemap file: (CODE) Sample code to add to the page menu: (CODE) Running the application, we wi…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

747 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now