On Thu, Jul 31, 2003 at 08:23:12AM -0700, Jason Carreira wrote: > I'm thinking of adding a feature which can be enabled from > webwork.properties to tell the SessionMap whether to synchronize access > to the HttpSession... I'll probably implement this as a subclass of > SessionMap which does the synchronization, and set up the code to create > the correct type of Map... Thoughts? >
IMO this is better implemented in the application using a filter. HttpSession session = req.getSession(); synchronized(session){ chain.doFilter(request, response); } Often you want to let the user know that he's trying to do something stupid (like, in a banking application when the user presses the same "withdraw $100-button" repeadetly), or let the view render completely before releasing the lock. Synchronizing access to the HttpSession might be a good thing "stand-alone" too, but people will still have to write an "outer synchronization block" using filters (in most cases). //Anders -- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Anders Engström [EMAIL PROTECTED] . http://www.gnejs.net PGP-Key: ED010E7F . [Your mind is like an umbrella. It doesn't work unless you open it.]
pgp00000.pgp
Description: PGP signature