Re: Session_OnEnd not firing sometimes?



Hello Chris,

You can use Application and Cache instead

read the MSDN to get more info about this


---
WBR, Michael Nemtsev [.NET/C# MVP] :: blog: http://spaces.live.com/laflour

"The greatest danger for most of us is not that our aim is too high and we miss it, but that it is too low and we reach it" (c) Michelangelo


CA> Hi michael,
CA> CA> Thanks for your response.
CA> CA> Is there any alternative? Maybe I could store some object in the
CA> session and have its finalizer do the clear up? Would this work, so
CA> when it is garbage collected (presumably at some point after there
CA> is no reference to it in Session scope), my clean up will happen
CA> because GC will call it's finalizer?
CA> CA> On 12 Dec, 12:43, Michael Nemtsev [MVP] <nemt...@xxxxxxx> wrote:
CA>
Hello Chris,

yep, it's still not relyable.
1) it works only for the InProc session management
2) With some SP (for VS or for Windows) it doesn't work at all - need
hotfix
---
WBR,
Michael Nemtsev [.NET/C# MVP] :: blog:http://spaces.live.com/laflour
"The greatest danger for most of us is not that our aim is too high
and we miss it, but that it is too low and we reach it" (c)
Michelangelo

CA> There seem to be isolated occurences of Session_OnEnd not firing
in
CA> my app. This is problematic because some clean up of resources
CA> happens here. I know the Session events were unreliable in
classic
CA> ASP, but is this still the case in ASP.Net?
CA>
CA> What kind of scenarios would case Session_OnEnd not to fire?
Would
CA> Application_Error being hit cause Session_OnEnd not to fire?
CA>


.



Relevant Pages

  • Re: Session_OnEnd not firing sometimes?
    ... no reference to it in Session scope), my clean up will happen because ... GC will call it's finalizer? ... This is problematic because some clean up of resources ... CA> What kind of scenarios would case Session_OnEnd not to fire? ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Session_End
    ... For example the SQL Server session state provider uses a job to perform ... "Guadala Harry" a écrit dans le message de ... > that Session_end would fire for every session end. ... > fire under normal circumstances (nothing special for state server, ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: session on end
    ... > offhanded reference to the unreliability of session on end. ... The real word is that it may not fire when you want or expect it to fire. ... Please reply to the newsgroup. ...
    (microsoft.public.inetserver.asp.general)
  • Re: Try...Catch...Finally not firing finally?
    ... always fire, there's an implicit guarantee for that. ... the Finally closes the connection. ... finishes the Catch then fires the Finally, which closes the session. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: =?UTF-8?B?U2Vzc2lvbiBzdGF0ZSBpc3N1ZQ==?=
    ... Application state lives as long as your application lives, session state on the other hand lives only as long as one session lives. ... This event DOES NOT fire when the user closes the browser. ... Don't confuse this) ...
    (microsoft.public.dotnet.framework.aspnet)