jboss « EntityManager « JPA Q&A

1. Problem on jboss lookup entitymanager    stackoverflow.com

I have my ear-project deployed in jboss 5.1GA. From webapp i don't have problem, the lookup of my ejb3 work fine! es:

ShoppingCart sc= (ShoppingCart) 
(new InitialContext()).lookup("idelivery-ear-1.0/ShoppingCartBean/remote");
also the iniection of my EntityManager work ...

2. JPA Entity Manager resource handling    stackoverflow.com

Every time I call JPA method its creating entity and binding query. My persistence properties are:

<property name="hibernate.dialect" value="org.hibernate.dialect.Oracle10gDialect"/>
<property name="hibernate.cache.provider_class"   value="net.sf.ehcache.hibernate.SingletonEhCacheProvider"/>
<property name="hibernate.cache.use_second_level_cache" value="true"/>
<property name="hibernate.cache.use_query_cache" value="true"/>
And I am creating entity manager ...

3. how inject a EntityManager between ear    stackoverflow.com

I'm using JBoss 4.2.3 and I deployed two ears called triad-1.0.ear and reportservices-1.0.ear, the thing is that I want to use the entity manager of the project triad in the project ...

4. Code hook before EntityManager is initialized in JBoss AS 6    stackoverflow.com

I'm looking for a callback facility that allows me to execute some code before an EntityManager is started in JBoss 6. More specifically, I would like to process a Liquibase changelog, before ...

5. What is the best way to handle a ConstraintViolationException with EJB3 and entitymanager in an SLSB    stackoverflow.com

here is my code snippet:

public class mySLSB {

@PersistenceContext(unitName = "db")
private EntityManager myEntityManager;

 public void crud(MyEntity myEntity) throws MyException {
However this merge can cause a ConstraintViolationException, which does not ...

6. EntityManager and bootstraping under jboss    forum.hibernate.org

Need help with Hibernate? Read this first: http://www.hibernate.org/ForumMailingli ... AskForHelp Hibernate version: 3.2.0.CR1 I am having a problem obtaining EntityManager in JBoss. I specified my persistence.xml file Code: org.hibernate.ejb.HibernatePersistence java:/OracleDS ...

7. problem with JBoss 4.0.5 + hibernate entitymanager    forum.hibernate.org

'm using: hibernate core 3.2.4 sp1 hibernate entitymanager 3.3.1GA hibernate annotations 3.3.0 GA but I always got the following error: 2007-07-14 18:21:54,421 ERROR [org.jboss.ejb.plugins.LogInterceptor] EJBException in method: public abstract hermes.simulate.ejb.SimpleEntityManager hermes.simulate.ejb.SimpleEntityManagerHome.create() throws javax.ejb.CreateException,java.rmi.RemoteException, causedBy: java.lang.reflect.UndeclaredThrowableException at org.jboss.ejb.plugins.AbstractInstancePool.get(AbstractInstancePool.java:204) at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invokeHome(StatelessSessionInstanceInterceptor.java:95) at org.jboss.ejb.plugins.CallValidationInterceptor.invokeHome(CallValidationInterceptor.java:56) at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:125) at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350) at org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:161) at org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:145) at org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:132) at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invokeHome(ProxyFactoryFinderInterceptor.java:107) at org.jboss.ejb.SessionContainer.internalInvokeHome(SessionContainer.java:637) at org.jboss.ejb.Container.invoke(Container.java:975) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at ...

8. JBoss: NonUniqueObjectException trashes EntityManager    forum.hibernate.org

I have a stateless session bean which parses and loads content from an XML file into a database. The document structure gets parse like so: Code: foreach section load descriptive data into descriptive table foreach alternate ID load base, alternate ID into mapping table ...