glassfish
  1. glassfish
  2. GLASSFISH-20967

Java EE 6/7 tutorial clientsessionmdb example: Deployment fails with MDB and durable subscription

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Blocker Blocker
    • Resolution: Invalid
    • Affects Version/s: 4.0_b89_RC5
    • Fix Version/s: None
    • Component/s: jms
    • Labels:
      None

      Description

      In chapter 46.7.2 Running the clientsessionmdb Example in the Java EE 6/7 tutorial example.
      I created the resources:
      >asadmin add-resources examples\jms\simple\producer\src\main\setup\glassfish-resources.xml
      >asadmin add-resources examples\jms\durablesubscriptionexample\durableconsumer\src\main\setup\glassfish-resources.xml

      Compiled and run build on the clientsessionmdb project in Netbeans 7.4.

      Got the following stacktrace:
      [2014-01-28T13:34:28.767+0100] [glassfish 4.0] [INFO] [ejb.glassfish_specific_jndi_names] [javax.enterprise.system.container.ejb.com.sun.ejb.containers] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912468767] [levelValue: 800] [[
      EJB5182:Glassfish-specific (Non-portable) JNDI names for EJB PublisherBean: javaeetutorial.clientsessionmdb.sb.PublisherRemote#javaeetutorial.clientsessionmdb.sb.PublisherRemote, javaeetutorial.clientsessionmdb.sb.PublisherRemote]]

      [2014-01-28T13:34:28.818+0100] [glassfish 4.0] [WARNING] [] [javax.jms.Connection.mqjmsra] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912468818] [levelValue: 900] [[
      MQJMSRA_DC2001: connectionId=9057657874187504384:_setClientID():JMSService.setClientId():JMSServiceException=setClientId: set client ID failed. Connection ID: 9057657874187504384, Client ID: MyID, Shareable: false, nameSpace: null Caused by:com.sun.messaging.jmq.jmsserver.util.BrokerException: conflict w/ clientID]]

      [2014-01-28T13:34:28.826+0100] [glassfish 4.0] [SEVERE] [] [javax.jms.Session.mqjmsra] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912468826] [levelValue: 1000] [[
      createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.]]

      [2014-01-28T13:34:28.827+0100] [glassfish 4.0] [WARNING] [endpoint.activation.failure] [javax.enterprise.resource.resourceadapter.com.sun.enterprise.connectors.inbound] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912468827] [levelValue: 900] [[
      RAR8501: Exception during endpoint activation for ra [ jmsra ], activationSpecClass [ com.sun.messaging.jms.ra.ActivationSpec ] : javax.resource.NotSupportedException: MQRA:EC:Error creating Direct Message Consumer:
      createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.]]

      [2014-01-28T13:34:28.827+0100] [glassfish 4.0] [SEVERE] [containers.mdb.create_container_exception] [javax.enterprise.system.container.ejb.mdb.org.glassfish.ejb.mdb] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912468827] [levelValue: 1000] [[
      MDB00017: [MessageBean]: Exception in creating message-driven bean container: [java.lang.Exception]]]

      [2014-01-28T13:34:28.828+0100] [glassfish 4.0] [SEVERE] [] [javax.enterprise.system.container.ejb.mdb.org.glassfish.ejb.mdb] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912468828] [levelValue: 1000] [[
      java.lang.Exception
      java.lang.Exception
      at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:215)
      at org.glassfish.ejb.mdb.MessageBeanContainer.<init>(MessageBeanContainer.java:252)
      at org.glassfish.ejb.mdb.MessageBeanContainerFactory.createContainer(MessageBeanContainerFactory.java:63)
      at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:221)
      at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:291)
      at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:99)
      at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:206)
      at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:313)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:493)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:219)
      at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:491)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:527)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:523)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.Subject.doAs(Subject.java:356)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2.execute(CommandRunnerImpl.java:522)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:546)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1423)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1500(CommandRunnerImpl.java:108)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1762)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1674)
      at org.glassfish.admin.rest.resources.admin.CommandResource.executeCommand(CommandResource.java:396)
      at org.glassfish.admin.rest.resources.admin.CommandResource.execCommandSimpInMultOut(CommandResource.java:234)
      at sun.reflect.GeneratedMethodAccessor1095.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:81)
      at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:125)
      at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:152)
      at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:91)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:346)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:341)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:101)
      at org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:224)
      at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271)
      at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:267)
      at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317)
      at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:198)
      at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:946)
      at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:331)
      at org.glassfish.admin.rest.adapter.JerseyContainerCommandService$3.service(JerseyContainerCommandService.java:165)
      at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:181)
      at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:246)
      at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:191)
      at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:168)
      at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:189)
      at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:288)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:206)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:136)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:114)
      at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
      at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:838)
      at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:113)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:55)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135)
      at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:564)
      at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:544)
      at java.lang.Thread.run(Thread.java:724)
      Caused by: javax.resource.NotSupportedException: MQRA:EC:Error creating Direct Message Consumer:
      createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:875)
      at com.sun.messaging.jms.ra.EndpointConsumer._init(EndpointConsumer.java:345)
      at com.sun.messaging.jms.ra.EndpointConsumer.<init>(EndpointConsumer.java:190)
      at com.sun.messaging.jms.ra.ResourceAdapter.endpointActivation(ResourceAdapter.java:458)
      at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:207)
      ... 62 more
      Caused by: com.sun.messaging.jms.IllegalStateException: createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jms.ra.DirectSession._createAndAddConsumer(DirectSession.java:1755)
      at com.sun.messaging.jms.ra.DirectSession.createDurableSubscriber(DirectSession.java:377)
      at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:852)
      ... 66 more
      Caused by: com.sun.messaging.jmq.jmsservice.JMSServiceException: addConsumer: Add consumer failed. Connection ID: 9057657874187504384, session ID: 9057657874187506176 Caused by:com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.addConsumer(IMQDirectService.java:1336)
      at com.sun.messaging.jms.ra.DirectSession._createAndAddConsumer(DirectSession.java:1701)
      ... 68 more
      Caused by: com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jmq.jmsserver.data.handlers.ConsumerHandler.checkClientID(ConsumerHandler.java:1045)
      at com.sun.messaging.jmq.jmsserver.data.handlers.ConsumerHandler.createConsumer(ConsumerHandler.java:691)
      at com.sun.messaging.jmq.jmsserver.data.protocol.ProtocolImpl.createConsumer(ProtocolImpl.java:569)
      at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.addConsumer(IMQDirectService.java:1318)
      ... 69 more
      ]]

      [2014-01-28T13:34:28.855+0100] [glassfish 4.0] [SEVERE] [] [javax.enterprise.system.tools.deployment.common] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912468855] [levelValue: 1000] [[
      Exception while invoking class org.glassfish.ejb.startup.EjbDeployer load method
      java.lang.RuntimeException: EJB Container initialization error
      at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:234)
      at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:291)
      at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:99)
      at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:206)
      at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:313)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:493)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:219)
      at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:491)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:527)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:523)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.Subject.doAs(Subject.java:356)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2.execute(CommandRunnerImpl.java:522)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:546)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1423)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1500(CommandRunnerImpl.java:108)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1762)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1674)
      at org.glassfish.admin.rest.resources.admin.CommandResource.executeCommand(CommandResource.java:396)
      at org.glassfish.admin.rest.resources.admin.CommandResource.execCommandSimpInMultOut(CommandResource.java:234)
      at sun.reflect.GeneratedMethodAccessor1095.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:81)
      at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:125)
      at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:152)
      at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:91)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:346)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:341)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:101)
      at org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:224)
      at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271)
      at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:267)
      at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317)
      at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:198)
      at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:946)
      at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:331)
      at org.glassfish.admin.rest.adapter.JerseyContainerCommandService$3.service(JerseyContainerCommandService.java:165)
      at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:181)
      at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:246)
      at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:191)
      at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:168)
      at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:189)
      at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:288)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:206)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:136)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:114)
      at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
      at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:838)
      at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:113)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:55)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135)
      at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:564)
      at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:544)
      at java.lang.Thread.run(Thread.java:724)
      Caused by: java.lang.Exception
      at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:215)
      at org.glassfish.ejb.mdb.MessageBeanContainer.<init>(MessageBeanContainer.java:252)
      at org.glassfish.ejb.mdb.MessageBeanContainerFactory.createContainer(MessageBeanContainerFactory.java:63)
      at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:221)
      ... 59 more
      Caused by: javax.resource.NotSupportedException: MQRA:EC:Error creating Direct Message Consumer:
      createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:875)
      at com.sun.messaging.jms.ra.EndpointConsumer._init(EndpointConsumer.java:345)
      at com.sun.messaging.jms.ra.EndpointConsumer.<init>(EndpointConsumer.java:190)
      at com.sun.messaging.jms.ra.ResourceAdapter.endpointActivation(ResourceAdapter.java:458)
      at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:207)
      ... 62 more
      Caused by: com.sun.messaging.jms.IllegalStateException: createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jms.ra.DirectSession._createAndAddConsumer(DirectSession.java:1755)
      at com.sun.messaging.jms.ra.DirectSession.createDurableSubscriber(DirectSession.java:377)
      at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:852)
      ... 66 more
      Caused by: com.sun.messaging.jmq.jmsservice.JMSServiceException: addConsumer: Add consumer failed. Connection ID: 9057657874187504384, session ID: 9057657874187506176 Caused by:com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.addConsumer(IMQDirectService.java:1336)
      at com.sun.messaging.jms.ra.DirectSession._createAndAddConsumer(DirectSession.java:1701)
      ... 68 more
      Caused by: com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jmq.jmsserver.data.handlers.ConsumerHandler.checkClientID(ConsumerHandler.java:1045)
      at com.sun.messaging.jmq.jmsserver.data.handlers.ConsumerHandler.createConsumer(ConsumerHandler.java:691)
      at com.sun.messaging.jmq.jmsserver.data.protocol.ProtocolImpl.createConsumer(ProtocolImpl.java:569)
      at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.addConsumer(IMQDirectService.java:1318)
      ... 69 more
      ]]

      [2014-01-28T13:34:29.149+0100] [glassfish 4.0] [SEVERE] [NCLS-CORE-00026] [javax.enterprise.system.core] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912469149] [levelValue: 1000] [[
      Exception during lifecycle processing
      java.lang.RuntimeException: EJB Container initialization error
      at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:234)
      at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:291)
      at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:99)
      at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:206)
      at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:313)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:493)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:219)
      at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:491)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:527)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:523)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.Subject.doAs(Subject.java:356)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2.execute(CommandRunnerImpl.java:522)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:546)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1423)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1500(CommandRunnerImpl.java:108)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1762)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1674)
      at org.glassfish.admin.rest.resources.admin.CommandResource.executeCommand(CommandResource.java:396)
      at org.glassfish.admin.rest.resources.admin.CommandResource.execCommandSimpInMultOut(CommandResource.java:234)
      at sun.reflect.GeneratedMethodAccessor1095.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:81)
      at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:125)
      at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:152)
      at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:91)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:346)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:341)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:101)
      at org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:224)
      at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271)
      at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:267)
      at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317)
      at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:198)
      at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:946)
      at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:331)
      at org.glassfish.admin.rest.adapter.JerseyContainerCommandService$3.service(JerseyContainerCommandService.java:165)
      at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:181)
      at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:246)
      at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:191)
      at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:168)
      at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:189)
      at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:288)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:206)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:136)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:114)
      at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
      at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:838)
      at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:113)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:55)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135)
      at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:564)
      at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:544)
      at java.lang.Thread.run(Thread.java:724)
      Caused by: java.lang.Exception
      at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:215)
      at org.glassfish.ejb.mdb.MessageBeanContainer.<init>(MessageBeanContainer.java:252)
      at org.glassfish.ejb.mdb.MessageBeanContainerFactory.createContainer(MessageBeanContainerFactory.java:63)
      at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:221)
      ... 59 more
      Caused by: javax.resource.NotSupportedException: MQRA:EC:Error creating Direct Message Consumer:
      createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:875)
      at com.sun.messaging.jms.ra.EndpointConsumer._init(EndpointConsumer.java:345)
      at com.sun.messaging.jms.ra.EndpointConsumer.<init>(EndpointConsumer.java:190)
      at com.sun.messaging.jms.ra.ResourceAdapter.endpointActivation(ResourceAdapter.java:458)
      at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:207)
      ... 62 more
      Caused by: com.sun.messaging.jms.IllegalStateException: createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jms.ra.DirectSession._createAndAddConsumer(DirectSession.java:1755)
      at com.sun.messaging.jms.ra.DirectSession.createDurableSubscriber(DirectSession.java:377)
      at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:852)
      ... 66 more
      Caused by: com.sun.messaging.jmq.jmsservice.JMSServiceException: addConsumer: Add consumer failed. Connection ID: 9057657874187504384, session ID: 9057657874187506176 Caused by:com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.addConsumer(IMQDirectService.java:1336)
      at com.sun.messaging.jms.ra.DirectSession._createAndAddConsumer(DirectSession.java:1701)
      ... 68 more
      Caused by: com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jmq.jmsserver.data.handlers.ConsumerHandler.checkClientID(ConsumerHandler.java:1045)
      at com.sun.messaging.jmq.jmsserver.data.handlers.ConsumerHandler.createConsumer(ConsumerHandler.java:691)
      at com.sun.messaging.jmq.jmsserver.data.protocol.ProtocolImpl.createConsumer(ProtocolImpl.java:569)
      at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.addConsumer(IMQDirectService.java:1318)
      ... 69 more
      ]]

      [2014-01-28T13:34:29.154+0100] [glassfish 4.0] [SEVERE] [] [javax.enterprise.system.core] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912469154] [levelValue: 1000] [[
      Exception while loading the app]]

      [2014-01-28T13:34:29.171+0100] [glassfish 4.0] [SEVERE] [] [javax.enterprise.system.core] [tid: _ThreadID=33 _ThreadName=admin-listener(1)] [timeMillis: 1390912469171] [levelValue: 1000] [[
      Exception while loading the app : EJB Container initialization error
      java.lang.Exception
      at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:215)
      at org.glassfish.ejb.mdb.MessageBeanContainer.<init>(MessageBeanContainer.java:252)
      at org.glassfish.ejb.mdb.MessageBeanContainerFactory.createContainer(MessageBeanContainerFactory.java:63)
      at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:221)
      at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:291)
      at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:99)
      at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:206)
      at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:313)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:493)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:219)
      at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:491)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:527)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:523)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.Subject.doAs(Subject.java:356)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$2.execute(CommandRunnerImpl.java:522)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:546)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1423)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1500(CommandRunnerImpl.java:108)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1762)
      at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1674)
      at org.glassfish.admin.rest.resources.admin.CommandResource.executeCommand(CommandResource.java:396)
      at org.glassfish.admin.rest.resources.admin.CommandResource.execCommandSimpInMultOut(CommandResource.java:234)
      at sun.reflect.GeneratedMethodAccessor1095.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:81)
      at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:125)
      at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:152)
      at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:91)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:346)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:341)
      at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:101)
      at org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:224)
      at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271)
      at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:267)
      at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317)
      at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:198)
      at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:946)
      at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:331)
      at org.glassfish.admin.rest.adapter.JerseyContainerCommandService$3.service(JerseyContainerCommandService.java:165)
      at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:181)
      at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:246)
      at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:191)
      at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:168)
      at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:189)
      at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:288)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:206)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:136)
      at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:114)
      at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
      at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:838)
      at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:113)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:55)
      at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135)
      at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:564)
      at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:544)
      at java.lang.Thread.run(Thread.java:724)
      Caused by: javax.resource.NotSupportedException: MQRA:EC:Error creating Direct Message Consumer:
      createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:875)
      at com.sun.messaging.jms.ra.EndpointConsumer._init(EndpointConsumer.java:345)
      at com.sun.messaging.jms.ra.EndpointConsumer.<init>(EndpointConsumer.java:190)
      at com.sun.messaging.jms.ra.ResourceAdapter.endpointActivation(ResourceAdapter.java:458)
      at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:207)
      ... 62 more
      Caused by: com.sun.messaging.jms.IllegalStateException: createConsumer on JMSService:jmsdirect failed for connectionId:9057657874187504384 and sessionId:9057657874187506176 due to [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jms.ra.DirectSession._createAndAddConsumer(DirectSession.java:1755)
      at com.sun.messaging.jms.ra.DirectSession.createDurableSubscriber(DirectSession.java:377)
      at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:852)
      ... 66 more
      Caused by: com.sun.messaging.jmq.jmsservice.JMSServiceException: addConsumer: Add consumer failed. Connection ID: 9057657874187504384, session ID: 9057657874187506176 Caused by:com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.addConsumer(IMQDirectService.java:1336)
      at com.sun.messaging.jms.ra.DirectSession._createAndAddConsumer(DirectSession.java:1701)
      ... 68 more
      Caused by: com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4135]: Cannot add durable consumer MySub. No ClientID was set on connection.
      at com.sun.messaging.jmq.jmsserver.data.handlers.ConsumerHandler.checkClientID(ConsumerHandler.java:1045)
      at com.sun.messaging.jmq.jmsserver.data.handlers.ConsumerHandler.createConsumer(ConsumerHandler.java:691)
      at com.sun.messaging.jmq.jmsserver.data.protocol.ProtocolImpl.createConsumer(ProtocolImpl.java:569)
      at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.addConsumer(IMQDirectService.java:1318)
      ... 69 more
      ]]

      One thing that I don't get is why messages did get delivered if I didn't create resources.
      (The message selector didn't work)

      Another this is why PublisherBean uses this lookup:java:module/jms/newsTopic
      instead of jms/MyTopic which was specified in the glassfish-resources.xml

        Activity

        Hide
        David Zhao added a comment - - edited

        geirot,

        I cannot reproduce it.

        My steps:

        1. Download JavaEE6TutorialExamples by "svn export https://svn.java.net/svn/javaeetutorial~svn/branches/javaee-tutorial-6/examples/JavaEE6TutorialExamples".

        2. asadmin add-resources JavaEE6TutorialExamples\jms\clientsessionmdb\setup\glassfish-resources.xml

        3. Open project clientsessionmdb in NetBeans 7.4

        4. Build project

        5. Deploy project

        It shows the deployment succeeds:

        asadmin deploy --force D:\work_dir\JavaEE6TutorialExamples\jms\clientsessionmdb\dist\clientsessionmdb.ear
        Application deployed with name clientsessionmdb.
        Command deploy executed successfully.

        And The durable consumer can be created successfully:

        ...\mq\bin>imqcmd list dur
        Username: admin
        Password:
        Listing all subscriptions
        -------------------------
        Host Primary Port
        -------------------------
        localhost 7676

        ------------------------------------------------------------------------------------------
        Subscription Name Client ID Destination Name Durable Messages Subscription State
        ------------------------------------------------------------------------------------------
        MySub MyID PhysicalTopic true 0 INACTIVE

        Successfully listed subscriptions.

        You reported this against 4.0_b89_RC5, is that the final release of GF4.0?

        Show
        David Zhao added a comment - - edited geirot, I cannot reproduce it. My steps: 1. Download JavaEE6TutorialExamples by "svn export https://svn.java.net/svn/javaeetutorial~svn/branches/javaee-tutorial-6/examples/JavaEE6TutorialExamples ". 2. asadmin add-resources JavaEE6TutorialExamples\jms\clientsessionmdb\setup\glassfish-resources.xml 3. Open project clientsessionmdb in NetBeans 7.4 4. Build project 5. Deploy project It shows the deployment succeeds: asadmin deploy --force D:\work_dir\JavaEE6TutorialExamples\jms\clientsessionmdb\dist\clientsessionmdb.ear Application deployed with name clientsessionmdb. Command deploy executed successfully. And The durable consumer can be created successfully: ...\mq\bin>imqcmd list dur Username: admin Password: Listing all subscriptions ------------------------- Host Primary Port ------------------------- localhost 7676 ------------------------------------------------------------------------------------------ Subscription Name Client ID Destination Name Durable Messages Subscription State ------------------------------------------------------------------------------------------ MySub MyID PhysicalTopic true 0 INACTIVE Successfully listed subscriptions. You reported this against 4.0_b89_RC5, is that the final release of GF4.0?
        Hide
        amyk added a comment - - edited

        I'v tried Java EE tutorial 7.0.3 example clientsessionmdb and it deploys and runs fine and no such exceptions as mentioned in Description shown in server.log and no exception in broker log, steps

        1. install GlassFish 4.0 final release build
        2. svn co https://svn.java.net/svn/javaeetutorial~svn/branches/javaeetutorial-7.0.3/examples/
        3. build the clientsessionmdb example, e.g. using netbeans
        4. deploy/run clientsessionmdb example. e.g. in netbeans following instruction at
        http://docs.oracle.com/javaee/7/tutorial/doc/jms-examples007.htm#BNCGW

        -----------------------------
        glassfish4/mq/bin/imqcmd list dur -u admin -pw admin

        Listing all subscriptions
        -------------------------
        Host Primary Port
        -------------------------
        localhost 7676

        ------------------------------------------------------------------------------------------
        Subscription Name Client ID Destination Name Durable Messages Subscription State
        ------------------------------------------------------------------------------------------
        MySub MyID PhysicalTopic true 0 ACTIVE

        Successfully listed subscriptions.
        -------------------------------

        [
        NOTE: If you use Java EE tutorial 6 example with GlassFish 4.0, before 'asadmin add-resources', you need to rename the connector-resource 'pool-name' and the connector-connection-pool 'name' in the example's glassfish-resource.xml, otherwise 'asadmin add-resources' gives error resourcename.isnot.unique (see JAVAEETUTORIAL-262). The following is 'imqcmd list dur' output for the Java EE tutorial 6 example after deploy to GlassFish 4.0, it works.

        Listing all subscriptions
        -------------------------
        Host Primary Port
        -------------------------
        localhost 7676

        ------------------------------------------------------------------------------------------
        Subscription Name Client ID Destination Name Durable Messages Subscription State
        ------------------------------------------------------------------------------------------
        MySub MyID PhysicalTopic true 0 ACTIVE

        Successfully listed subscriptions.
        ]

        Show
        amyk added a comment - - edited I'v tried Java EE tutorial 7.0.3 example clientsessionmdb and it deploys and runs fine and no such exceptions as mentioned in Description shown in server.log and no exception in broker log, steps 1. install GlassFish 4.0 final release build 2. svn co https://svn.java.net/svn/javaeetutorial~svn/branches/javaeetutorial-7.0.3/examples/ 3. build the clientsessionmdb example, e.g. using netbeans 4. deploy/run clientsessionmdb example. e.g. in netbeans following instruction at http://docs.oracle.com/javaee/7/tutorial/doc/jms-examples007.htm#BNCGW ----------------------------- glassfish4/mq/bin/imqcmd list dur -u admin -pw admin Listing all subscriptions ------------------------- Host Primary Port ------------------------- localhost 7676 ------------------------------------------------------------------------------------------ Subscription Name Client ID Destination Name Durable Messages Subscription State ------------------------------------------------------------------------------------------ MySub MyID PhysicalTopic true 0 ACTIVE Successfully listed subscriptions. ------------------------------- [ NOTE: If you use Java EE tutorial 6 example with GlassFish 4.0, before 'asadmin add-resources', you need to rename the connector-resource 'pool-name' and the connector-connection-pool 'name' in the example's glassfish-resource.xml, otherwise 'asadmin add-resources' gives error resourcename.isnot.unique (see JAVAEETUTORIAL-262 ). The following is 'imqcmd list dur' output for the Java EE tutorial 6 example after deploy to GlassFish 4.0, it works. Listing all subscriptions ------------------------- Host Primary Port ------------------------- localhost 7676 ------------------------------------------------------------------------------------------ Subscription Name Client ID Destination Name Durable Messages Subscription State ------------------------------------------------------------------------------------------ MySub MyID PhysicalTopic true 0 ACTIVE Successfully listed subscriptions. ]

          People

          • Assignee:
            David Zhao
            Reporter:
            geirot
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: