That's strange. http://fisheye.labs.jboss.com/viewrep/JBoss/jboss-seam/src/main/org/jboss/seam/util/Persistence.java?r=MAIN shows your code. But it doesn't work for me since getDelegate() returns an instance of org.hibernate.ejb.EntityManagerInstance. So I had to use this:
( (EntityManagerImpl) em.getDelegate() ).getSession().setFlushMode(FlushMode.NEVER); Now there aren't any auto-flushes anymore. But: explicit calls of flush() don't work either.javax.persistence.TransactionRequiredException: no transaction is in progressSo I think you must explicitely open and close transactions... what is not only a bit silly since it makes me lose some of EJB3s convenience stuff. It even doesn't work for me now: ejbCtx.getUserTransaction().begin() em.getTransaction.begin() ( (EntityManagerImpl) em.getDelegate() ).getSession().beginTransaction() ( (EntityManagerImpl) em.getDelegate() ).getSession().getTransaction().begin() ... they all throw Exceptions So this is where I'm stuck ^^. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3965551#3965551 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3965551 _______________________________________________ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user