6 Replies Latest reply on Jan 26, 2003 8:31 AM by slaboure

    Fail-Over and Load-balancing

    tahirhussain

      Hi All,
      We are facing a problem related to fail-over and loadbalancing.
      We have 3 JBoss nodes (all different machines) in the App tier clustering environment. On 2 nodes we have deployed all our EJBs. And the ip-address of third one is specified for lookup of beans

      To access the JBOSS nodes we are using Tomcat 4.0.1 as our web server.

      Initially we has all the nodes and the Tomcat server running. Load balancing was taking place. Now we pulled down one JBOSS node - A (with EJB deployed). The whole load was being taken up by the other JBOSS node - B.

      Next we started the previously down node (A)and pulled down JBOSS node (B).

      Now the observation is no requests are coming to any of the JBOSS nodes. While on the Tomcat side exception is being thrown.

      Could u please throw some light on the problem
      Thanks
      Tahir




        • 1. Re: Fail-Over and Load-balancing
          slaboure

          Which version of JBoss? Which exception is being thrown on the tomcat side?

          • 2. Re: Fail-Over and Load-balancing
            tahirhussain

            we are using JBoss3.0.1RC1 and Tomcat4.0.3

            The exception received at Tomcat side is :

            java.lang.ArrayIndexOutOfBoundsException: 1 at com.lntinfotech.hol.textchat.web.action.TextChatRequestProcessor.parseRefreshRequest(Unknown Source)at com.lntinfotech.hol.textchat.web.action.TextChatRequestProcessor.processRequest(Unknown Source)at com.lntinfotech.hol.poller.web.PollerServlet$ProcessRequestThread.run(Unknown Source)
            [ 9:32 18-32-03] Could Not Instantiate class::com.lntinfotech.hol.commonservices.web.action.CSRequestProcessor : IN CLASS "com.lntinfotech.hol.poller.web.RequestProcessorFactory" METHOD "createRequestProcessor"
            com.lntinfotech.hol.util.HOLException: null.pointer.exception at com.lntinfotech.hol.poller.web.RequestProcessorFactory.createRequestProcessor(Unknown Source) at com.lntinfotech.hol.poller.web.PollerServlet$ProcessRequestThread.run(Unknown Source)
            Caused by: java.lang.NullPointerException
            at org.jboss.ha.jndi.HAJNDI.lookup HAJNDI.java:192)
            at sun.reflect.GeneratedMethodAccessor38.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at org.jboss.ha.framework.server.HARMIServerImpl.invoke(HARMIServerImpl.java:158)
            at sun.reflect.GeneratedMethodAccessor37.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
            at sun.rmi.transport.Transport$1.run(Transport.java:148)
            at java.security.AccessController.doPrivileged(Native Method)
            at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
            at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
            at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
            at java.lang.Thread.run(Thread.java:536)
            at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:247)
            at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)
            at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:133)
            at org.jboss.ha.framework.server.HARMIServerImpl_Stub.invoke(Unknown Source)
            at org.jboss.ha.framework.interfaces.HARMIClient.invokeRemote(HARMIClient.java:120)
            at org.jboss.ha.framework.interfaces.HARMIClient.invoke(HARMIClient.java:187)
            at $Proxy0.lookup(Unknown Source)
            at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:450)
            at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:434)
            at javax.naming.InitialContext.lookup(InitialContext.java:354)
            at com.lntinfotech.hol.util.EJBHomeFactory.getHome(Unknown Source)
            at com.lntinfotech.hol.commonservices.web.action.CSRequestProcessor.(Unknown Source)
            at sun.reflect.GeneratedConstructorAccessor34.newInstance(Unknown Source)
            at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
            at java.lang.reflect.Constructor.newInstance(Constructor.java:274)
            at java.lang.Class.newInstance0(Class.java:306)
            at java.lang.Class.newInstance(Class.java:259)
            ... 2 more

            • 3. Re: Fail-Over and Load-balancing
              tahirhussain

              JBoss version JBOSS3.0.1RC1

              • 4. Re: Fail-Over and Load-balancing
                slaboure

                Read the stacktrace: it seems to indidate that the bug is in YOUR code:

                com.lntinfotech.hol.textchat.web.action.TextChatRequestProcessor.parseRefreshRequest

                • 5. Re: Fail-Over and Load-balancing

                  Further into the stacktrace is:

                  Caused by: java.lang.NullPointerException
                  at org.jboss.ha.jndi.HAJNDI.lookup HAJNDI.java:192)

                  which is in HAJNDI.java.

                  • 6. Re: Fail-Over and Load-balancing
                    slaboure

                    Oups, sorry, you are right!

                    3.0.1RC1 is *very* very old! Please try again with 3.0.6 which incorporates *many* fixes.

                    Cheers,


                    sacha