From: Henrique S. (JIRA) <no...@at...> - 2006-06-14 19:36:39
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-511?page=comments#action_23339 ] Henrique Sousa commented on HHH-511: ------------------------------------ For EJB 3.0 this is failing due to a listener and and clear() is not called for the EntityManager. We must track changes to an entity, so in the pre-update callback we store a copy of the current entity and refresh it to get the old values. When I restore the updated state and let the flush() process continue this exception is raised. I cannot evict() the parent object because it still has to be saved and there is no such method in EntityManager. > reattach object from same session > --------------------------------- > > Key: HHH-511 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-511 > Project: Hibernate3 > Type: Bug > Components: core > Reporter: Gavin King > Priority: Minor > > > http://forum.hibernate.org/viewtopic.php?p=2231400#2231400 > There is a problem when you reattach a collection to the same session that it was previously attached to, after calling clear(). Hibernate checks the collections session reference, at reattach and concludes it is already attached. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |