*
The moose likes EJB and other Java EE Technologies and the fly likes Could not enlist in transaction on entering meta-aware object! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Could not enlist in transaction on entering meta-aware object!" Watch "Could not enlist in transaction on entering meta-aware object!" New topic
Author

Could not enlist in transaction on entering meta-aware object!

Henrique Ordine
Ranch Hand

Joined: Sep 03, 2004
Posts: 127
Hello everyone,

I have a transaction which spans 2 session beans and each of these session beans interact with a different EntityManager. Also, these EntityManagers interact with different data sources.

The problem is, when I try to call o method on the second EntityManager, I get this "Could not enlist in transaction on entering meta-aware object!" exception.

I've read somewhere that if I invoke another sessionbean from a session bean (which is my case), I should use the same PersistenceContext in both EJBs. But I can't do this, since my PersistenceContexts point to different data sources.

Is there a way around this?


J2EE Architect/Developer
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 10068
    
163

Have you configured your datasources to be XA?


[My Blog] [JavaRanch Journal]
Henrique Ordine
Ranch Hand

Joined: Sep 03, 2004
Posts: 127
Not really, but thanks Jaikiran Pai, I'll try that.
 
 
subject: Could not enlist in transaction on entering meta-aware object!