Re: [OFFTOPIC] Removing attribute from all HttpSessions

2004-08-19 Thread Tim Funk
not actually called when a user closes their browser but on session timeout after inactivity correct? Allistair Crossley -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: 19 August 2004 11:48 To: Tomcat Users List Subject: Re: [OFFTOPIC] Removing attribute from all

RE: [OFFTOPIC] Removing attribute from all HttpSessions

2004-08-19 Thread Allistair Crossley
Sent: 19 August 2004 11:48 > To: Tomcat Users List > Subject: Re: [OFFTOPIC] Removing attribute from all HttpSessions > > > Look at the SessionListeners to register all the sessions > that match your > criteria into a map. Then whatever is listening on your > invalidati

Re: [OFFTOPIC] Removing attribute from all HttpSessions

2004-08-19 Thread Tim Funk
Look at the SessionListeners to register all the sessions that match your criteria into a map. Then whatever is listening on your invalidation strategy can update the map. (Actually - the sessions in the map) -Tim Allistair Crossley wrote: Hey, I am putting a page caching stategy into place per

RE: [OFFTOPIC] Removing attribute from all HttpSessions

2004-08-19 Thread Allistair Crossley
ions. Perhaps I need to store the caches created per session somewhere so I can grab them. Allistair Crossley > -Original Message- > From: Michiel Toneman [mailto:[EMAIL PROTECTED] > Sent: 19 August 2004 09:57 > To: Tomcat Users List > Subject: Re: [OFFTOPIC] Removing a

Re: [OFFTOPIC] Removing attribute from all HttpSessions

2004-08-19 Thread Michiel Toneman
Bad caching strategy. Try using a singleton cache backed by a HashMap. Have an invalidation method that takes a pagekey as argument. Create a simple get(pagekey) that checks for invalidation and refills the cache entry when necessary. No need to go iterating over sessions... Just my $0.02 :-) Mi

[OFFTOPIC] Removing attribute from all HttpSessions

2004-08-19 Thread Allistair Crossley
Hey, I am putting a page caching stategy into place per user session. However, there are times when I need to refresh all the caches for all users. For example, let's say 5 users have a cached version of page 5. An external event causes page 5 to invalidate. I need an effective strategy to flus