0 Replies Latest reply on Aug 11, 2004 8:44 AM by vivek oswal

    configuration problems regarding High Availability JMS with

    vivek oswal Newbie

      hi all,

      Versions: jboss3.2.5 with tomcat 5 and jdk 1.4.2 on Windows 2000 with apache 2.0.45 as load balancer.
      Cluster formed on 2 jboss servers ankit and vivek. The apache loadbalancer is configured on ankit.

      The test given for High Availability JMS with JBossMQ on the wiki http://www.jboss.org/wiki/Wiki.jsp?page=JBossMQHA does'nt run as expected on our setup.
      We get the following exception when we stop the HASingletonDeployer on the current master node.

      16:53:44,309 INFO [HAJMSClient] HA JMS message published to topic: VIVEK
      16:54:16,132 WARN [BasicQueue] Error during stop - removing subscriber Subscrip
      tion[subId=-2147483648connection=ConnectionToken:ID:2/c036c0e140942aa51635ed147f
      214f43 destination=QUEUE.testQueue messageSelector=null Local Create]
      javax.jms.InvalidDestinationException: The subscription was registered with a de
      stination that does not exist !
      at org.jboss.mq.server.ClientConsumer.removeSubscription(ClientConsumer.
      java:246)
      at org.jboss.mq.server.BasicQueue.stop(BasicQueue.java:640)
      at org.jboss.mq.server.JMSQueue.close(JMSQueue.java:152)
      at org.jboss.mq.server.JMSDestinationManager.closeDestination(JMSDestina
      tionManager.java:806)
      at org.jboss.mq.server.jmx.DestinationMBeanSupport.stopService(Destinati
      onMBeanSupport.java:138)
      at org.jboss.system.ServiceMBeanSupport.jbossInternalStop(ServiceMBeanSu
      pport.java:319)
      at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMB
      eanSupport.java:223)
      at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.server.ReflectedDispatcher.dispatch(ReflectedDispatcher.
      java:60)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:61)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:53)
      at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
      at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
      java:185)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:473)
      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceControl
      ler.java:837)
      at $Proxy17.stop(Unknown Source)
      at org.jboss.system.ServiceController.stop(ServiceController.java:449)
      at org.jboss.system.ServiceController.stop(ServiceController.java:440)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
      java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.server.ReflectedDispatcher.dispatch(ReflectedDispatcher.
      java:60)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:61)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:53)
      at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
      at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
      java:185)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:473)
      at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:176)
      at $Proxy4.stop(Unknown Source)
      at org.jboss.deployment.SARDeployer.stop(SARDeployer.java:285)
      at org.jboss.deployment.MainDeployer.stop(MainDeployer.java:492)
      at org.jboss.deployment.MainDeployer.stop(MainDeployer.java:507)
      at org.jboss.deployment.MainDeployer.undeploy(MainDeployer.java:475)
      at org.jboss.deployment.MainDeployer.undeploy(MainDeployer.java:470)
      at org.jboss.deployment.MainDeployer.undeploy(MainDeployer.java:443)
      at org.jboss.deployment.MainDeployer.undeploy(MainDeployer.java:458)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
      java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.server.ReflectedDispatcher.dispatch(ReflectedDispatcher.
      java:60)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:61)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:53)
      at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
      at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
      java:185)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:473)
      at org.jboss.ha.singleton.HASingletonController.invokeSingletonMBeanMeth
      od(HASingletonController.java:114)
      at org.jboss.ha.singleton.HASingletonController.stopSingleton(HASingleto
      nController.java:89)
      at org.jboss.ha.singleton.HASingletonSupport._stopOldMaster(HASingletonS
      upport.java:159)
      at org.jboss.ha.singleton.HASingletonSupport.partitionTopologyChanged(HA
      SingletonSupport.java:123)
      at org.jboss.ha.jmx.HAServiceMBeanSupport$1.replicantsChanged(HAServiceM
      BeanSupport.java:197)
      at org.jboss.ha.framework.server.DistributedReplicantManagerImpl.notifyK
      eyListeners(DistributedReplicantManagerImpl.java:701)
      at org.jboss.ha.framework.server.DistributedReplicantManagerImpl.remove(
      DistributedReplicantManagerImpl.java:352)
      at org.jboss.ha.jmx.HAServiceMBeanSupport.unregisterDRMListener(HAServic
      eMBeanSupport.java:213)
      at org.jboss.ha.jmx.HAServiceMBeanSupport.stopService(HAServiceMBeanSupp
      ort.java:159)
      at org.jboss.system.ServiceMBeanSupport.jbossInternalStop(ServiceMBeanSu
      pport.java:319)
      at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMB
      eanSupport.java:223)
      at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.server.ReflectedDispatcher.dispatch(ReflectedDispatcher.
      java:60)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:61)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:53)
      at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
      at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
      java:185)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:473)
      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceControl
      ler.java:837)
      at $Proxy17.stop(Unknown Source)
      at org.jboss.system.ServiceController.stop(ServiceController.java:449)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
      java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.server.ReflectedDispatcher.dispatch(ReflectedDispatcher.
      java:60)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:61)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:53)
      at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
      at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
      java:185)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:473)
      at org.jboss.system.ServiceMBeanSupport.stop(ServiceMBeanSupport.java:18
      0)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
      java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.server.ReflectedDispatcher.dispatch(ReflectedDispatcher.
      java:60)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:61)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:53)
      at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
      at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
      java:185)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:473)
      at org.jboss.jmx.adaptor.control.Server.invokeOpByName(Server.java:234)
      at org.jboss.jmx.adaptor.control.Server.invokeOp(Server.java:200)
      at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.invokeOp(HtmlAdaptorSer
      vlet.java:241)
      at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.processRequest(HtmlAdap
      torServlet.java:79)
      at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.doPost(HtmlAdaptorServl
      et.java:61)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
      icationFilterChain.java:237)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
      ilterChain.java:157)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
      alve.java:214)
      at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
      eContext.java:104)
      at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
      a:520)
      at org.apache.catalina.core.StandardContextValve.invokeInternal(Standard
      ContextValve.java:198)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
      alve.java:152)
      at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
      eContext.java:104)
      at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(Securit
      yAssociationValve.java:72)
      at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
      eContext.java:102)
      at org.jboss.web.tomcat.security.JBossSecurityMgrRealm.invoke(JBossSecur
      ityMgrRealm.java:275)
      at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
      eContext.java:102)
      at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
      a:520)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
      ava:137)
      at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
      eContext.java:104)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
      ava:117)
      at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
      eContext.java:102)
      at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
      a:520)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
      ve.java:109)
      at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
      eContext.java:104)
      at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
      a:520)
      at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)

      at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:16
      0)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
      :799)
      at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proce
      ssConnection(Http11Protocol.java:705)
      at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java
      :577)
      at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadP
      ool.java:683)
      at java.lang.Thread.run(Thread.java:534)
      16:54:16,148 INFO [TomcatDeployer] undeploy, ctxPath=/jbossmq-httpil, warUrl=fi
      le:/C:/jboss-3.2.5/server/all/deploy-hasingleton/jms/jbossmq-httpil.sar/jbossmq-
      httpil.war/
      17:29:00,685 INFO [HAJMSClient] Registering durable subscriber


      Also we never get the following message:
      "Notification received by ExceptionListener" on the server console where the client is installed after stoping the HASingletonDeployer.

      The rest of the steps(in the test) don't live up to their expectation after this.
      The configuration for jboss-3.2.5 is not changed in anyways. We use the exact same deployable as provided in the download, except for the following
      descriptor which allows for pointing to shared hypersonic database.i.e. the hsqldb-ds.xml in all/deploy folder.
      We are listing the changed parts only:

      <!-- CHANGED, we uncommented this. for tcp connection, allowing other processes to use the hsqldb
       database. This requires the org.jboss.jdbc.HypersonicDatabase mbean.
       -->
       <connection-url>jdbc:hsqldb:hsql://ankit:1701</connection-url>
      
       <!-- for totally in-memory db, not saved when jboss stops.
       The org.jboss.jdbc.HypersonicDatabase mbean necessary
       <connection-url>jdbc:hsqldb:.</connection-url>
       -->
       <!-- CHANGED. We commented this. for in-process persistent db, saved when jboss stops. The
       org.jboss.jdbc.HypersonicDatabase mbean is necessary for properly db shutdown
      
       <connection-url>jdbc:hsqldb:${jboss.server.data.dir}${/}hypersonic${/}localDB</connection-url>
       -->
       <driver-class>org.hsqldb.jdbcDriver</driver-class>
       <user-name>sa</user-name>
       <password></password>
       <min-pool-size>5</min-pool-size>
       <max-pool-size>20</max-pool-size>
       <idle-timeout-minutes>0</idle-timeout-minutes>
       <track-statements/>
       <security-domain>HsqlDbRealm</security-domain>
       <!-- CHANGED. We commented this. This mbean can be used when using in process persistent hypersonic
       <depends>jboss:service=Hypersonic,database=localDB</depends>
       -->
       </local-tx-datasource>
      
       <!-- CHANGED. We uncommented this. This mbean should be used only when using tcp connections. Uncomment
       when the tcp based connection-url is used. -->
       <mbean code="org.jboss.jdbc.HypersonicDatabase"
       name="jboss:service=Hypersonic">
       <attribute name="Port">1701</attribute>
       <attribute name="Silent">true</attribute>
       <attribute name="Database">default</attribute>
       <attribute name="Trace">false</attribute>
       <attribute name="No_system_exit">true</attribute>
       </mbean>
       <!-- CHANGED. We commented this. This mbean can be used when using in process persistent db
       <mbean code="org.jboss.jdbc.HypersonicDatabase"
       name="jboss:service=Hypersonic,database=localDB">
       <attribute name="Database">localDB</attribute>
       <attribute name="InProcessMode">true</attribute>
       </mbean>
       -->

      We can't figure out what causes the above exception, but somehow this is the root cause(visibly atleast!).
      Any help is welcome.

      Thanks and Regards,
      Ankit Nevatia