I am trying to integrate some EJBs into a predominantly Spring application, hosted on tomEE+ and I'm just not understanding how to get the persistence context to propagate along with a transaction that starts in an EJB and invokes a method from a Spring bean.
I have set up container managed datasources, transaction manager, and entitymanager (here's a relevant snippet from an applicationContext.xml). Anything that is entirely Spring or entirely EJB works just fine. But, if I get hold of a managed entity within an EJB and then invoke a method from a Spring bean, passing the entity as an argument, the Spring bean thinks its unmanaged. This is in spite of the EJB method being declared @TransactionAttribute and the Spring method being declared @Transactional with propagation Mandatory. Somehow the persistence context is not propagating with the transaction. Any ideas? -- View this message in context: http://openejb.979440.n4.nabble.com/Shared-Persistence-Context-between-Spring-Beans-and-EJBs-tp4664343.html Sent from the OpenEJB User mailing list archive at Nabble.com.
