The object that created from the Hibernate session is a plain POJO. Does it mean that once the hibernate session is closed, the object became an "ophan" and would cause synchronization problem if I use it?
-----Original Message----- From: Patrick Casey [mailto:[EMAIL PROTECTED] Sent: Friday, May 06, 2005 10:42 AM To: 'Tapestry users' Subject: RE: Error: JTATransaction Could not register Synchronization (Tapestry +Hibernate) Does the object in question have uninitialized collections and/or proxies references on it? If so it'll try to use the (closed) session to resolve these references if it needs to. You can potentially work around this. Given an "orphan" object foo (an object whose session has been closed) Session newSession = ConfigurationFactory.createSession(); newSession.lock(orphan, LockMode.NONE); The above will associate the object with the new "fresh" session and let it resolve proxies or lazy collections again. --- Pat -----Original Message----- From: Patrick Yip [mailto:[EMAIL PROTECTED] Sent: Friday, May 06, 2005 10:27 AM To: Tapestry users Subject: Error: JTATransaction Could not register Synchronization (Tapestry +Hibernate) I keep getting this error: JTATransaction Could not register Synchronization. And I can't find the cause of it. Question: will this cause the problem? I created an object from a hibernate session and then set it as a property on the next page The hibernate session is closed immediately in the current page before activating the next page. When I continue on the next page and start using the object reference I set earlier, would this cause the above error? Any comment is greatly appreciated. -Patrick --------------------------------------------------------------------- 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]
