5 Replies Latest reply on Sep 8, 2010 8:42 AM by Galder Zamarreño

    Help on Clustering decision

    Rohit Macherla Novice

      This is more of a generic question.


      As a part of our JBoss scalability, we are considering different things to do, including clustering and load balancing. I was going through the Clustering docs of JBoss (the Administration and Configuration guide at http://docs.jboss.org/jbossas/docs/Administration_And_Configuration_Guide/5/html_single/index.html#clustering-intro) and found this sentence in the "Introduction" part of chapter 16 (Clustering) :
      "Clustering allows us to run an application on several parallel servers (a.k.a cluster nodes) while providing a single view to application clients. Load is distributed across different servers, and even if one or more of the servers fails, the application is still accessible via the surviving cluster nodes."

       

      I remember reading, somewhere else too, about how we can configure our jboss-web and web.xml's  to distribute the load.

       

      What confuses me is the fact that this user guide advocates the use of Apache and mod_jk for HTTP load balancing (Refer Chapter 20). I read about JBoss's "client side interceptors" vs "external load balancers", but came under the impression that usage of Client side interceptors balances the load. If we do need a load balancer, then I think that statement in the introduction really misled me, isn't it ?

       

      Generic question: If I have only WebServices deployed on JBoss (Servlets / state less session beans), then what is the advantage we get out of clustering ? Isn't load balancing enough? What are the criteria that I should consider, provided that I don't need state replication (no stateful session beans/entity beans/jsp's) to make a decision between using clustering or going for a software load balancer or both ?
      I am assuming it'll be an overload to opt for clustering in this situation.

       

      Oh, and we'd be using JBoss 5.1

      (Note: If this is not the right forum for this question, I'd be glad if you'd point out the right one. Thanks for your time)

        • 1. Re: Help on Clustering decision
          kaddy k Newbie

          Hi Rohit,

           

          I am also doing some research on jboss 5.1 clustering (mainly for server failover and sessoin replication) and I am in the same situation as mention by you in this thread. If you already got some idea about this, can you please share it ? I want to deploy an EAR (contains war and EJB jar) on a cluster of 2-3 servers

          • 2. Re: Help on Clustering decision
            Rohit Macherla Novice

            Hi Kaddy,

             

            Currently, we are trying to analyze the use of mod_jk vs Oracle's WebCache as a HTTP load balancing option. From the documents I've read, it appears that the load-balancing strategies mentioned for EJB's would only serve as a help to the load balancer, but does not load balance by itself.

             

            Since your applications are stateful and you need session replication, JBoss 5.1 is already doing good at it. Please look at the clustering guide offered by JBoss docs. I went through "JBoss in Action" and felt it had some good documentation for clustering. We didn't need session replication, so opted out of clustering.

             

            Cheers,

            Rohit M

            • 3. Re: Help on Clustering decision
              Jesus Salvo Newbie

              Rohit Macherla wrote:

               

              What confuses me is the fact that this user guide advocates the use of Apache and mod_jk for HTTP load balancing (Refer Chapter 20). I read about JBoss's "client side interceptors" vs "external load balancers", but came under the impression that usage of Client side interceptors balances the load. If we do need a load balancer, then I think that statement in the introduction really misled me, isn't it ?

               


               

              If I understand you correctly, you want load-balanced HTTP requests to your servlets / webservices.

               

              I believe you are confusing "client side interceptor" ( used with EJB, JNDI, RMI clients ... anywhere where a stub or code is downloaded by the client from a server and such stub / code has knowledge of the network topology of the cluster ) and "external load balancers" ( in this context, HTTP load balancers .. e.g. mod_jk / Cisco hardware, etc ).

               

              To load-balance HTTP requests / posts, you do need an HTTP load balancer ( like Apache mod_jk or a Cisco hardware ) that knows / configured with knowledge of what webservers are available, and potentially recognize / understand HTTP stickyness ( in the event you want the same HTTP session to hit the same webserver ).

              • 4. Re: Help on Clustering decision
                kaddy k Newbie

                Hi Rohit and Jesus,

                 

                I have an ear file (contain war and several jar files  including ejb.jar) that I want to deploy in JBoss cluster for session  replication and server fail-over. I am confused with the apprach that I  should follow for this, a load balancer or client side interceptor ?

                 

                Thanks  in advance.

                • 5. Re: Help on Clustering decision
                  Galder Zamarreño Master

                  Jesus, that's a very good response.

                   

                  Kaddy, read Jesus' reply. It all comes down to what technology is used to serve incoming requests, whether these are HTTP requests, or remote EJB calls...etc