Sure, I would like to take a look. Could you email it to me or make it available?
On 2/22/06, James Carman <[EMAIL PROTECTED]> wrote: > Well, I wrote something pretty cool the other day. It's a new storage > strategy for Tapestry called "entity." Basically, if you try to store an > object as a persistent page property that is a persistent entity, it doesn't > store the actual object. It stores its identity information > (entityName/id). If the object isn't persistent yet (an object you created > via the "new" operator), it just stores it as-is in the session. If you > would like the code, configuration information, just let me know. > > > > -----Original Message----- > From: Anthony Fox [mailto:[EMAIL PROTECTED] > Sent: Wednesday, February 22, 2006 8:12 AM > To: Tapestry users > Subject: hibernate detached objects as persistent page properties > > Hi, > > I have an application that has a lot of hibernate detached objects > (with lazy loaded collections) that are persistent page properties. > What are best practices for reattaching these detached objects while > maintaining a clean separation of layers? I have my implementation > specific persistence layer separated into DAOs, a service layer, and > the tapestry ui layer. I would like to keep tapestry independent of > the persistence layer. I am using the OpenSessionInView pattern to > open a new hibernate session for each web request. However, I can't > determine a clean way to reattach all the hibernate detached objects > at the beginning of each web request. I've noticed that some people > use pageBeginRender() to reattach objects, but I don't want to expose > my tapestry code to the persistence implementation. An interceptor or > filter or something that separated the ui layer from being aware of > the persistence layer would be ideal. How have others dealt with this > issue? > > Thanks, > Anthony > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
