| Author |
iis restart and Session _onEnd
|
|
|
| When IIS is restarted session_onEnd is called. though the debugger is not
available at this point in Session_onEnd, is there any way that the code in
session_onEnd is running due to iis restart and not from the timeout.
thanks
| |
|
| I mean is there anyway to detect in session_onend that code is running due
to IIS restart or timeout....
"abcd" <abcd@abcd.com> wrote in message
news:ekl0F9YNHHA.1248@TK2MSFTNGP03.phx.gbl...
> When IIS is restarted session_onEnd is called. though the debugger is not
> available at this point in Session_onEnd, is there any way that the code
> in session_onEnd is running due to iis restart and not from the timeout.
>
> thanks
>
| |
| Evertjan. 2007-01-11, 6:56 pm |
| abcd wrote on 11 jan 2007 in microsoft.public.inetserver.asp.general:
> "abcd" <abcd@abcd.com> wrote in message
> news:ekl0F9YNHHA.1248@TK2MSFTNGP03.phx.gbl...
[Please do not toppost on usenet even your own posting]
[color=darkred]
> I mean is there anyway to detect in session_onend that code is running
> due to IIS restart
> or timeout....
[The session can also end by software command.]
try:
if application("firstSessionOnEnd") = "" then
'' do your one time things
application("firstSessionOnEnd") = "hasFiredBefore"
else
'' do things that you only want to do at later times
end if
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
| |
|
| thanks Evertjan. But how this will help me to detect the differnce bettween
timeout and explicit IIS restart...in both situations code in session_onend
runs
"Evertjan." <exjxw.hannivoort@interxnl.net> wrote in message
news:Xns98B5A59B9ACEEeejj99@194.109.133.242...
> abcd wrote on 11 jan 2007 in microsoft.public.inetserver.asp.general:
>
>
> [Please do not toppost on usenet even your own posting]
>
>
>
> [The session can also end by software command.]
>
> try:
>
> if application("firstSessionOnEnd") = "" then
> '' do your one time things
> application("firstSessionOnEnd") = "hasFiredBefore"
> else
> '' do things that you only want to do at later times
> end if
>
>
>
> --
> Evertjan.
> The Netherlands.
> (Please change the x'es to dots in my emailaddress)
| |
| Evertjan. 2007-01-12, 6:56 pm |
| abcd wrote on 12 jan 2007 in microsoft.public.inetserver.asp.general:
> "Evertjan." <exjxw.hannivoort@interxnl.net> wrote in message
> news:Xns98B5A59B9ACEEeejj99@194.109.133.242...
[color=darkred]
> thanks Evertjan. But how this will help me to detect the differnce
> bettween timeout and explicit IIS restart...in both situations code in
> session_onend runs
I agree. My example would not work. However:
Further thinking brings me to doubt your first point.
Say:
1 The server stops because the power fails.
2 The server restarts manually or automaticly.
3 So IIS restarts.
Question:
The Session_onEnd of what session is executed?
Of all sessions that existed before the crash?
=====
It is a longtime adagium in this NG never to use Session_onEnd for
serious business, you cannot trust it.
==============
Answer: It destroys the order of the conversation
Question: Why?
Answer: Top-Posting.
Question: Whats the most annoying thing on Usenet?
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
|
|
|
|