Matej, I do not understand your point :-( The object does not get replicated when a reference to it is stored in the session. So I understand point b, but in case no clustering is used, why would there be a memory problem? Putting a reference in the session is just a way to keep a handle on the object. Having the reference the session is not different from having it anywhere else, as far as memory is concerned. Or is it?
Pierre-Yves Matej Knopp a écrit : > Putting large objects into session is ok, as long as you > > a) have enough memory and can afford it > b) don't replicate the session (clustering). > > -Matej > > Pierre-Yves Saumont wrote: >> I already tried this method, but it is called just before the user can >> see the page. What I need is to do something when he leaves the page. >> >> However, I think I have found an acceptable solution. I would make all >> my data objects implements an interface (let's say Lockable) and >> retain the last locked object in the session. That way, I can release >> the last locked object on each new request (if needed). The risk is to >> have the last object locked until the session expires, but that's >> acceptable in my use case. >> >> However, I red many times that big objects should not be put in the >> session. Putting an object in the session is just a matter of >> retaining a reference to it. So it should not cost much. Or do I miss >> something? >> >> Pierre-Yves >> >> Eelco Hillenius a écrit : >>>> Is there a Wicket (ie really smart) way to detext when the user switch >>>> to another page? >>>> >>>> The use case is to release locks that a user might have put on database >>>> records with pessimistic locking when the user switch to another page. >>> For every request target that was set during a request (like for >>> everytime you called setResponsePage), onDetach will be called at the >>> end of the request handling. This is the place where you should clean >>> up resources for normal requests. >>> >>> Eelco >>> >>> ------------------------------------------------------------------------- >>> >>> Using Tomcat but need to do more? Need to support web services, >>> security? >>> Get stuff done quickly with pre-integrated technology to make your >>> job easier >>> Download IBM WebSphere Application Server v.1.0.1 based on Apache >>> Geronimo >>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >>> _______________________________________________ >>> Wicket-user mailing list >>> [email protected] >>> https://lists.sourceforge.net/lists/listinfo/wicket-user >>> >>> >>> >> >> >> ------------------------------------------------------------------------- >> Using Tomcat but need to do more? Need to support web services, security? >> Get stuff done quickly with pre-integrated technology to make your job >> easier >> Download IBM WebSphere Application Server v.1.0.1 based on Apache >> Geronimo >> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >> _______________________________________________ >> Wicket-user mailing list >> [email protected] >> https://lists.sourceforge.net/lists/listinfo/wicket-user >> > > > > ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Wicket-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/wicket-user
