One thing to remember is web applications are designed to be stateless. The
idea is there is a request from a client (generally a browser) and a
response from the server. To fake a session, a server cookie is set on the
client side. This type of cookie is not disabled when one disables client
cookies, so do not think of this as your typical cookie, except that both
send their information with every request. State is an illusion created by
using these session items (like a server cookie).
Now that you have that down, consider what happens to sessions that do not
need your timer when you extend a session timeout to five days. Everyone who
hits the application takes up memory for five days, or until the application
dies.
If you need a timer to run, you are better to set up a windows service that
will handle the timer. You can fire it off from your web application, if you
would like, but consider it a one way trip.
Short answer: You can configure this "timer" to stay up longer, but you may
end up with some bad effects.
--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA
*************************************************
| Think outside the box!
|
*************************************************
"Rob" <rob_nicholson@nospam_unforgettable.comwrote in message
news:zu*******************@newsfe3-win.ntli.net...
In a previous thread, I was asking about setting up my global.aspx which
inherits System.Web.HttpApplication. This is where there are the event
handlers like:
Sub Session_Start(ByVal sender As Object, ByVal e As EventArgs)
Sub Application_Error(ByVal sender As Object, ByVal e As EventArgs)
In this file I've got:
Private WithEvents ApplicationTimer As System.Timers.Timer ' used to
generate application events
and the associated:
Private Sub ApplicationTimer_Elapsed(ByVal sender As Object, ByVal e As
System.Timers.ElapsedEventArgs) Handles ApplicationTimer.Elapsed
This works fine but for some reason, the timer stopped running after a
while. I had left the application idle on the web server. Do application
events continue to run forever even after all sessions on the webapp have
timed out/finished?
Cheers, Rob.