1

i'm use hibernate4 lucene4 in EJB3.

it ran perfectly but when i added a transaction in first managed bean. the InitialContext return : javax naming not found in ctx.lookup("java:comp/UserTransaction");

ex = (javax.naming.NamingException) javax.naming.NamingException: Lookup failed for 'java:comp/UserTransaction' in SerialContext[myEnv=java.naming.factory.initial=com.sun.enterprise.naming.impl.SerialInitContextFactory, java.naming.factory.state=com.sun.corba.ee.impl.presentation.rmi.JNDIStateFactoryImpl, java.naming.factory.url.pkgs=com.sun.enterprise.naming} [Root exception is javax.naming.NameNotFoundException: Recherche de java:comp/UserTransaction non autorisée pour les beans Transaction gérés par le conteneur]

I think, the context implementation is different, and he need a props in InitialContext,

  1. I called the ejb transaction from simple class from first managed bean,
  2. I called InitialContext from another EJB3 from two managed bean
CodeClown42
  • 11,194
  • 1
  • 32
  • 67

0 Answers0