If the process is interrupted, or something happens out of the ordinary on the server, that might be missed. I had a project that required this not too long ago, I wrote something that checked for a lack of activity for the period that the session activity was set to, and removed the user from the list manually if the session end event was somehow missed. Of course this means that if the user didn't properly log out they will appear to be "online" for whatever is left in the session expire time (default of 20 minutes). This was good enough for what the guy paying me wanted, so I didn't do anything fancier. I followed a link someone posted to this list I believe called "heartbeat" which was a fairly nice setup for taking care of this problem. Check the list archives or Google, or maybe whoever posted that will chime in. Scott Phelps
_____ From: Ali Husain [mailto:[EMAIL PROTECTED] Sent: Thursday, January 20, 2005 8:46 PM To: [email protected] Subject: RE: [AspNetAnyQuestionIsOk] Does .net know when client closes browser? Charles. thanks for the info on session End, I always wondered about that as well. Is it poor programming to use session end to determine someone who never logged out and then remove them from a list of currently logged on users? Thanks, Ali -----Original Message----- From: Charles Carroll [mailto:[EMAIL PROTECTED] Sent: Thursday, January 20, 2005 10:10 AM To: [email protected] Subject: Re: [AspNetAnyQuestionIsOk] Does .net know when client closes browser? session end theoretically fires after 20 minutes of silence from a session owner. But it is not guaranteed because there is a chance that 1. the server software could screw up and not notice 100% of the client's silence 2. if aspnet_wp.exe restarts due to problem the people using the site may not notice but the worker process may be too screwed up to dot its I's and cross its T's and take care of fring all session ends. That being the case smart programmers for many decades store data permanently when they get it and may cache it to speed up access but NO PROGRAMMER WHO WANTS A RELIABLE APP stores any data in session end. They store data when they get it and cache it or fetch it fast as needed. They store tokens (i.e. person id 178 goes with this clump of db data) in sessions only and maybe cached data in caches or session but if anyone updates that data they place it back in DB on the spot not at session end. An inexperienced programmer who never has tested their systems extensively thinks gather data from n web pages and store it as session end. A veteran stores it as he gathers each piece and never procrastinates for an event that may not happen. On Thu, 20 Jan 2005 16:18:32 -0000, scaevola637 <[EMAIL PROTECTED]> wrote: > > I dont think it does, but am just crurious. If it does know, should > not sessionend event (or sessionabandon) fire? > > > > > > ________________________________ > Yahoo! Groups Links > > To visit your group on the web, go to: > http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/ > > To unsubscribe from this group, send an email to: > [EMAIL PROTECTED] > > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. _____ Yahoo! Groups Links * To visit your group on the web, go to: http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/ * To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED] cribe> * Your use of Yahoo! Groups is subject to the Yahoo! Terms of <http://docs.yahoo.com/info/terms/> Service. [Non-text portions of this message have been removed] _____ Yahoo! Groups Links * To visit your group on the web, go to: http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/ * To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED] e> * Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service <http://docs.yahoo.com/info/terms/> . [Non-text portions of this message have been removed] Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
