The problem with sticking entities in the HttpSession is they get detached when the request ends. If you're trying to do lazy loading after they're detached it won't work.
What I do now is stick the id in the session instead of the entity then I have a getUser() either in a base ActionBean or ActionBeanContext that loads the entity if not cached, caches it, and gives it back. The other option is to force the lazy loading properties to load before the entity gets detached but that gets to be a maintenance nightmare. Aaron Lionel wrote: > I need the user on each request for visibility filters and to display its > name. > I don't want to load the user on each request, and would like to avoid > second level cache... > > > > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Stripes-users mailing list > Stripes-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/stripes-users > > ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Stripes-users mailing list Stripes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/stripes-users