My problem was that instead of checking if the entity is detached using EntityManager.contains() method I just invoked persist and I merged only in case of exception. This only proves that I don't understand EJB 3.0.
1. Why the thrown exception corrupted the entity manager?? It was caught in the very same method! Is this expected behaviour? 2. Why my entities become detached in the first place? I use extended PersistenceContext. They should be managed all the time, shouldn't they? View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3935005#3935005 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3935005 ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 _______________________________________________ JBoss-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/jboss-user
