[jboss-user] [JBoss Seam] - Re: Using the JPA delegate
eirirlar
do-not-reply at jboss.com
Tue Feb 27 18:24:47 EST 2007
It seems that the entityManager.getDelegate() returns either a SessionImpl or a EntityManagerImpl, depending on wether or not you have the following set up in your components.xml:
<core:managed-persistence-context name="bookingDatabase"
| auto-create="true"
| persistence-unit-jndi-name="java:/EntityManagerFactories/bookingData"/>
and persistence.xml:
<property name="jboss.entity.manager.factory.jndi.name"
| value="java:/EntityManagerFactories/bookingData"/>
That is - if this is set up, SessionImpl is returned. Otherwise EntitiyManagerImpl is returned.
I can't really find a logical explanation for this, but it's not a problem as long as I know about it.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4023362#4023362
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4023362
More information about the jboss-user
mailing list