1 Reply Latest reply on Mar 30, 2010 8:47 AM by Nicklas Karlsson

    Message Driven Beans - Attack of the Clone (messages)

    Ian R Newbie

      (At least you know the title of my next post if I find another bug!)


      I think I've found another problem with Weld and MDBs. The context of this error is when a message is on the queue, and this error occurs upon startup. If the message appears on the queue while the application is running, there are no issues with the bean.


      Any ideas? I'm running JBoss AS 6.0.0 M2 with Weld 1.0.1 Final.


      Thanks,


      Ian




      08:31:22,290 ERROR [org.jboss.aspects.tx.TxPolicy] javax.ejb.EJBTransactionRolledbackException: Unable to inject jndi dependency: env/org.jboss.weld.integration.ejb.SessionBeanInterceptor/beanManager into property org.jboss.weld.integration.ejb.SessionBeanInterceptor.beanManager: WELD-001300 Unable to locate BeanManager
      08:31:22,306 ERROR [org.jboss.resource.adapter.jms.inflow.JmsServerSession] Unexpected error delivering message delegator->JBossMessage[5201300667662377]:PERSISTENT, deliveryId=0: javax.ejb.EJBTransactionRolledbackException: Unable to inject jndi dependency: env/org.jboss.weld.integration.ejb.SessionBeanInterceptor/beanManager into property org.jboss.weld.integration.ejb.SessionBeanInterceptor.beanManager: WELD-001300 Unable to locate BeanManager
           at org.jboss.ejb3.tx.Ejb3TxPolicy.handleInCallerTx(Ejb3TxPolicy.java:115)
           at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:130)
           at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:194)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.ejb3.tx.NullInterceptor.invoke(NullInterceptor.java:42)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.ejb3.security.Ejb3AuthenticationInterceptorv2.invoke(Ejb3AuthenticationInterceptorv2.java:80)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.ejb3.BlockContainerShutdownInterceptor.invoke(BlockContainerShutdownInterceptor.java:67)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.aspects.currentinvocation.CurrentInvocationInterceptor.invoke(CurrentInvocationInterceptor.java:67)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.ejb3.interceptor.EJB3TCCLInterceptor.invoke(EJB3TCCLInterceptor.java:86)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.ejb3.mdb.MessagingContainer.localInvoke(MessagingContainer.java:282)
           at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.delivery(MessageInflowLocalProxy.java:299)
           at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.invoke(MessageInflowLocalProxy.java:152)
           at $Proxy305.onMessage(Unknown Source)
           at org.jboss.resource.adapter.jms.inflow.JmsServerSession.onMessage(JmsServerSession.java:179)
           at org.jboss.jms.client.container.ClientConsumer.callOnMessageStatic(ClientConsumer.java:160)
           at org.jboss.jms.client.container.SessionAspect.handleRun(SessionAspect.java:831)
           at org.jboss.aop.advice.org.jboss.jms.client.container.SessionAspect_z_handleRun_31249897.invoke(SessionAspect_z_handleRun_31249897.java)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.jms.client.container.ClosedInterceptor.invoke(ClosedInterceptor.java:170)
           at org.jboss.aop.advice.PerInstanceInterceptor.invoke(PerInstanceInterceptor.java:86)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.jms.client.delegate.ClientSessionDelegate.run(ClientSessionDelegate.java)
           at org.jboss.jms.client.JBossSession.run(JBossSession.java:199)
           at org.jboss.resource.adapter.jms.inflow.JmsServerSession.run(JmsServerSession.java:236)
           at org.jboss.resource.work.WorkWrapper.run(WorkWrapper.java:172)
           at org.jboss.threads.SimpleDirectExecutor.execute(SimpleDirectExecutor.java:33)
           at org.jboss.threads.QueueExecutor.runTask(QueueExecutor.java:780)
           at org.jboss.threads.QueueExecutor.access$100(QueueExecutor.java:45)
           at org.jboss.threads.QueueExecutor$Worker.run(QueueExecutor.java:821)
           at java.lang.Thread.run(Thread.java:619)
           at org.jboss.threads.JBossThread.run(JBossThread.java:122)
      Caused by: java.lang.RuntimeException: Unable to inject jndi dependency: env/org.jboss.weld.integration.ejb.SessionBeanInterceptor/beanManager into property org.jboss.weld.integration.ejb.SessionBeanInterceptor.beanManager: WELD-001300 Unable to locate BeanManager
           at org.jboss.injection.JndiPropertyInjector.lookup(JndiPropertyInjector.java:82)
           at org.jboss.injection.JndiPropertyInjector.inject(JndiPropertyInjector.java:99)
           at org.jboss.injection.JndiPropertyInjector.inject(JndiPropertyInjector.java:89)
           at org.jboss.ejb3.interceptor.InterceptorInjector.inject(InterceptorInjector.java:49)
           at org.jboss.ejb3.EJBContainer.createInterceptor(EJBContainer.java:328)
           at org.jboss.ejb3.BaseContext.initialiseInterceptorInstances(BaseContext.java:112)
           at org.jboss.ejb3.pool.AbstractPool.create(AbstractPool.java:85)
           at org.jboss.ejb3.pool.AbstractPool.create(AbstractPool.java:73)
           at org.jboss.ejb3.pool.StrictMaxPool.get(StrictMaxPool.java:146)
           at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:58)
           at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
           at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:126)
           ... 34 more
      Caused by: javax.naming.NamingException: Could not dereference object [Root exception is javax.naming.NamingException: WELD-001300 Unable to locate BeanManager]
           at org.jnp.interfaces.NamingContext.resolveLink(NamingContext.java:1356)
           at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:819)
           at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:688)
           at org.jboss.ejb3.JndiUtil.lookup(JndiUtil.java:44)
           at org.jboss.injection.JndiPropertyInjector.lookup(JndiPropertyInjector.java:75)
           ... 45 more
      Caused by: javax.naming.NamingException: WELD-001300 Unable to locate BeanManager
           at org.jboss.weld.resources.ManagerObjectFactory.getObjectInstance(ManagerObjectFactory.java:50)
           at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304)
           at org.jnp.interfaces.NamingContext.getObjectInstance(NamingContext.java:1483)
           at org.jnp.interfaces.NamingContext.getObjectInstanceWrapFailure(NamingContext.java:1500)
           at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:824)
           at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:688)
           at javax.naming.InitialContext.lookup(InitialContext.java:392)
           at org.jnp.interfaces.NamingContext.resolveLink(NamingContext.java:1350)
           ... 49 more