3 Replies Latest reply on Jul 5, 2009 10:36 PM by Clebert Suconic

    MessagingException when deploying ear

    Naresh Bhatia Novice

      I am getting the following MessagingException when I deploy my ear. I am using JBoss Messaging 2.0.0.BETA3. Any idea why this could be happening? (The same ear on another machine with JBM 2.0.0.BETA1 is working just fine.)

      org.jboss.deployers.spi.DeploymentException: Endpoint activation failed ra=jboss.jca:service=RARDeployment,name='jms-ra.rar' activationSpec=org.jboss.messaging.ra.inflow.JBMActivationSpec(ra=org.jboss.messaging.ra.JBMResourceAdapter@673a6164 destination=queue/exchange.to.bfseam.fix.queue destinationType=javax.jms.Queue tx=true durable=false user=null maxMessages=1 minSession=1 maxSession=15 keepAlive=60000)
       at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
       at org.jboss.ejb3.mdb.inflow.JBossMessageEndpointFactory.activate(JBossMessageEndpointFactory.java:346)
       at org.jboss.ejb3.mdb.inflow.JBossMessageEndpointFactory.start(JBossMessageEndpointFactory.java:212)
       at org.jboss.ejb3.mdb.MessagingContainer.startProxies(MessagingContainer.java:224)
       at org.jboss.ejb3.mdb.MessagingContainer.lockedStart(MessagingContainer.java:176)
       at org.jboss.ejb3.EJBContainer.start(EJBContainer.java:884)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.reflect.plugins.introspection.ReflectionUtils.invoke(ReflectionUtils.java:59)
       at org.jboss.reflect.plugins.introspection.ReflectMethodInfoImpl.invoke(ReflectMethodInfoImpl.java:150)
       at org.jboss.joinpoint.plugins.BasicMethodJoinPoint.dispatch(BasicMethodJoinPoint.java:66)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction$JoinpointDispatchWrapper.execute(KernelControllerContextAction.java:241)
       at org.jboss.kernel.plugins.dependency.ExecutionWrapper.execute(ExecutionWrapper.java:47)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchExecutionWrapper(KernelControllerContextAction.java:109)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchJoinPoint(KernelControllerContextAction.java:70)
       at org.jboss.kernel.plugins.dependency.LifecycleAction.installActionInternal(LifecycleAction.java:221)
       at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:54)
       at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:42)
       at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
       at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
       at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
       at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)
       at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:774)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:540)
       at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:121)
       at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:51)
       at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
       at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)
       at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:171)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1439)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1157)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1178)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1210)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1098)
       at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)
       at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
       at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
       at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:781)
       at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:702)
       at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
       at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:362)
       at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:255)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
       at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
       at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
       at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
       at java.lang.Thread.run(Thread.java:619)
      Caused by: javax.resource.ResourceException: unable to start Activation
       at org.jboss.messaging.ra.inflow.JBMActivation.start(JBMActivation.java:273)
       at org.jboss.messaging.ra.JBMResourceAdapter.endpointActivation(JBMResourceAdapter.java:139)
       at org.jboss.resource.deployers.RARDeployment.endpointActivation(RARDeployment.java:330)
       at org.jboss.resource.deployers.RARDeployment.internalInvoke(RARDeployment.java:284)
       at org.jboss.system.ServiceDynamicMBeanSupport.invoke(ServiceDynamicMBeanSupport.java:156)
       at org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:164)
       at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
       at org.jboss.ejb3.JmxClientKernelAbstraction.invoke(JmxClientKernelAbstraction.java:58)
       at org.jboss.ejb3.mdb.inflow.JBossMessageEndpointFactory.activate(JBossMessageEndpointFactory.java:342)
       ... 59 more
      Caused by: MessagingException[errorCode=2 message=Unable to connect to server using configuration org-jboss-messaging-core-remoting-impl-invm-InVMConnectorFactory?jbm-remoting-invm-serverid=0]
       at org.jboss.messaging.core.client.impl.ConnectionManagerImpl.createSession(ConnectionManagerImpl.java:294)
       at org.jboss.messaging.core.client.impl.ClientSessionFactoryImpl.createSessionInternal(ClientSessionFactoryImpl.java:962)
       at org.jboss.messaging.core.client.impl.ClientSessionFactoryImpl.createSession(ClientSessionFactoryImpl.java:706)
       at org.jboss.messaging.ra.JBMResourceAdapter.createSession(JBMResourceAdapter.java:1261)
       at org.jboss.messaging.ra.inflow.JBMActivation.setupSession(JBMActivation.java:359)
       at org.jboss.messaging.ra.inflow.JBMActivation.setup(JBMActivation.java:306)
       at org.jboss.messaging.ra.inflow.JBMActivation.start(JBMActivation.java:269)
       ... 67 more
      


        • 1. Re: MessagingException when deploying ear
          Clebert Suconic Master

          Take a look at the configuration and the MDB example.

          On Beta1, the InVM acceptor existed by default, and that changed on Beta2. You now have to define it explicitally.


          I believe we didn't add the acceptor on the default configuration.


          Can you open jbm-configuration.xml, and add the following snippet of code?

           <connectors>
           <connector name="netty">
           <factory-class>org.jboss.messaging.integration.transports.netty.NettyConnectorFactory</factory-class>
           <param key="jbm.remoting.netty.host" value="${jbm.remoting.netty.host:localhost}" type="String"/>
           <param key="jbm.remoting.netty.port" value="${jbm.remoting.netty.port:5445}" type="Integer"/>
           </connector>
          
           <connector name="in-vm">
           <factory-class>org.jboss.messaging.core.remoting.impl.invm.InVMConnectorFactory</factory-class>
           </connector>
          
           </connectors>
          
          



          take a look at examples/javaee/mdb/server/jbm-configuration.xml


          • 2. Re: MessagingException when deploying ear
            Naresh Bhatia Novice

            Clebert, thanks so much for the pointers. You are correct, the default configuration in beta3 does not contain either the in-vm connector or the acceptor. After adding both, the exception went away.

            Just out of curiosity, is this intentional? I would prefer that the default configuration worked right out of the box. I know JMS, but having to learn about acceptors, connectors and configuration is yet another impediment for noobs to adopt JBM. In any case, JBM 2.0 is looking like a great product in the making. Keep up the good work!

            Thanks.
            Naresh

            • 3. Re: MessagingException when deploying ear
              Clebert Suconic Master

              No.. not intentional. We will fix it.


              thanks for pointing it out.