3 Replies Latest reply on Aug 4, 2006 2:45 AM by Maarten Roosendaal

    HA-JNDI in Cluster on 1 machine?

    Maarten Roosendaal Newbie

      Hi,

      Does HA-JNDI work on a cluster on a single machine? When you want to configure a cluster on 1 machine you have to change the port-bindings but since HA-JNDI requires 1 general port number to work it seems that it can't work out of the box?

      How can you accomplish this or what am i missing?

      Thanks,
      MAarten

        • 1. Re: HA-JNDI in Cluster on 1 machine?
          Ben Wang Master

          Sure, HA-JNDI will work on a sinlge node cluster, although realistically you wouldn't do that.

          • 2. Re: HA-JNDI in Cluster on 1 machine?
            Maarten Roosendaal Newbie

            So when i deploy my application (which contains a Spring JMS-client that looks up the ConnectionFactory and does some batchprocessing) in the farm folder, the instance on the second node should see the ConnectionFactory and thus be able to send messages to the queue on the master node?

            Even if you had to change the port settings so that HA-JNDI is available on port 1200 on the second node? I had to do that because i got binding exceptions.

            • 3. Re: HA-JNDI in Cluster on 1 machine?
              Maarten Roosendaal Newbie

              I tried deploying a simple MDB on a 2 node cluster on a multihomed machine. I followed the instructions according to the wiki-page (http://wiki.jboss.org/wiki/Wiki.jsp?page=ConfiguringMultipleJBossInstancesOnOneMachine). deployment on the masternode works fine but when the deployment on the second node gets pulled i get:
              2006-08-04 07:58:44,787 INFO [org.jboss.ejb.EjbModule] Deploying SpGBerichtDispatcherMDB
              2006-08-04 07:58:45,476 WARN [org.jboss.ejb.plugins.jms.JMSContainerInvoker] JMS provider failure detected:
              org.jboss.deployment.DeploymentException: Error during queue setup; - nested throwable: (javax.jms.InvalidDestinationException: The destination QUEUE.lo3_queue does not exist !)
              at org.jboss.deployment.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:39)
              at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerCreate(JMSContainerInvoker.java:898)
              at org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:922)
              at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:272)
              at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:222)
              at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:324)
              ......

              What i did was the following:

              changed conf/jboss-service.xml to enable clustering (node = ports-01, node2 = ports-02)



              changed deploy/cluster-service.xml on the second node (we use 4.0.2 and has a bug concerning port 4446) and used 4447.



              added bind_addr in both cluster-service.xml's



              added our own jms.xml to deploy-hasingleton/jms (and we see the queue on the masternode.


              What am i missing? Did i forget to change a setting. I also tried changing the hajndi-jms-ds.xml on both nodes to the corresponding port but no luck either.

              Hope someone can help!

              Thanks,
              Maarten