tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chawax <olivier.thie...@gmail.com>
Subject Re: PersistenceContext and Hibernate session
Date Fri, 11 Jul 2008 15:09:48 GMT

I tried this :

    protected org.hibernate.ejb.HibernateEntityManager emanager;

    @javax.persistence.PersistenceContext(unitName = "t4Seam")    
    public void setEntityManager(javax.persistence.EntityManager
entityManager) {
    	this.emanager = (org.hibernate.ejb.HibernateEntityManager)
entityManager;
    }

But I have a ClassCastException :

    java.lang.ClassCastException:
org.apache.openejb.persistence.JtaEntityManager

Is there a place where I could configure the entity manager to use Hibernate
one instead of OpenEJB one ?
-- 
View this message in context: http://www.nabble.com/PersistenceContext-and-Hibernate-session-tp18404318p18406052.html
Sent from the OpenEJB User mailing list archive at Nabble.com.


Mime
View raw message