Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

ASP.NET Forum


You are currently viewing our ASP.NET Forum as a guest. Please register to participate.
Login



Reply
Only 90 sec for my script to execute?
Old 04-17-2007, 03:07 AM Only 90 sec for my script to execute?
Average Talker

Posts: 21
Name: Robert Brue
Trades: 0
Please, can anyone help me with this issue. My script needs more than 90 sec to execute, but hosting provider (shared hosting) has this time interval as time out. What should I do to give the script more time to execute?
__________________

Please login or register to view this content. Registration is FREE
- Get one way text links with different anchors for free.
Add your website here:

Please login or register to view this content. Registration is FREE
urlslivecom is offline
Reply With Quote
View Public Profile Visit urlslivecom's homepage!
 
 
Register now for full access!
Old 04-17-2007, 06:45 AM Re: Only 90 sec for my script to execute?
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
server.scripttimeout = value_in_seconds

though I would be giving serious thought to improving the script performance.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 04-17-2007, 09:55 PM Re: Only 90 sec for my script to execute?
Banned

Posts: 510
Name: CHRIS
Location: I live in Google's Home State
Trades: 0
Is this to long of a time for your script to do this? Or is it a good time for you. Maybe you can tell me this and then I will be able to help you out more easily.
Vasity is offline
Reply With Quote
View Public Profile Visit Vasity's homepage!
 
Old 04-18-2007, 02:32 AM Re: Only 90 sec for my script to execute?
Average Talker

Posts: 21
Name: Robert Brue
Trades: 0
"server.scripttimeout = value_in_seconds" - where this line of code should be? My script is sending emails to some users, and it send around 10 emails in 90 sec interval, but I need to send much more emails. It's not spam or something like. These emails are notifications about new content.
__________________

Please login or register to view this content. Registration is FREE
- Get one way text links with different anchors for free.
Add your website here:

Please login or register to view this content. Registration is FREE
urlslivecom is offline
Reply With Quote
View Public Profile Visit urlslivecom's homepage!
 
Old 04-18-2007, 02:53 AM Re: Only 90 sec for my script to execute?
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,938
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Trades: 0
If your script is only sending 10 emails in 90 seconds, something is seriously slowing it down.

Are you sending attachments? HTML emails? Both? Whatever it is, that's way too long. That's an email every 9 seconds.

As far as where to put that script timeout, put it just before you start executing any code (usually immediately after Option Explicit is fine.)
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
(my blog)


Please login or register to view this content. Registration is FREE
(with proof)
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Old 04-19-2007, 03:29 AM Re: Only 90 sec for my script to execute?
Average Talker

Posts: 21
Name: Robert Brue
Trades: 0
Quote:
Originally Posted by ADAM Web Design View Post
If your script is only sending 10 emails in 90 seconds, something is seriously slowing it down.

Are you sending attachments? HTML emails? Both? Whatever it is, that's way too long. That's an email every 9 seconds.

As far as where to put that script timeout, put it just before you start executing any code (usually immediately after Option Explicit is fine.)
No attachments or HTML, just plain text email. But there is DNSless connection to Access database where all information about receiver is stored. All email bodies are unique, because of name and needed personal code inserted. For sending email "CDO.Message" is used. And, yes, it seems 9 sec. interval for 1 email is too long to be considered as acceptable.
__________________

Please login or register to view this content. Registration is FREE
- Get one way text links with different anchors for free.
Add your website here:

Please login or register to view this content. Registration is FREE
urlslivecom is offline
Reply With Quote
View Public Profile Visit urlslivecom's homepage!
 
Old 04-19-2007, 05:50 AM Re: Only 90 sec for my script to execute?
ForrestCroce's Avatar
Half Man, Half Amazing

Posts: 3,023
Name: Forrest Croce
Location: Seattle, WA
Trades: 0
If you think the Access connection could be the issue, break the code apart into two loops. First read all the data from the Access query into arrays, then close the db connection, and loop through the arrays and fire off the emails. That won't solve the problem itself ( unless it's a cursor issue ), but it's a bit more efficient of an approach, and if you add some logging code, you can figure out exactly where the problem is.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
ForrestCroce is offline
Reply With Quote
View Public Profile Visit ForrestCroce's homepage!
 
Old 04-19-2007, 07:51 AM Re: Only 90 sec for my script to execute?
Average Talker

Posts: 18
Trades: 0
90 Seconds is definetly too long. Good luck with the debugging!
Swefx is offline
Reply With Quote
View Public Profile
 
Old 04-19-2007, 03:50 PM Re: Only 90 sec for my script to execute?
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
The newsletter script I coded for a client can fire off 250 individual email HTML or plain text messages (depending on recipient settings) in under 40 seconds.

As Forrest says it connects to the DB, gets the info once and then constructs and sends the messages.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Reply     « Reply to Only 90 sec for my script to execute?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.29012 seconds with 12 queries