Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-5884

Support for multiple mod_cluster configurations (load-balancing on multiple ports)

    XMLWordPrintable

    Details

      Description

      Earlier I asked on forums https://developer.jboss.org/message/946476#946476

      on our wf8.2 server the web-app have two http endpoints: on port 8080 to regular http requests; and on port 37304 to "special" user requests in protected area.

      we want use mod_cluster as load-balancer that balances user requests on both ports. For example(see the pic), lets requests on balancer`s port 7801 will be balance between node1 and node2 on port 8080, and requests on balancer`s port 7802 will be balance on port 37304.

      In modcluster-subsystem configuration in standalone.xml we can set only one connector for mod-cluster config. And cannot set more than one mod-cluster-config section:

      jboss-as-mod-cluster_1_2.xsd
            <xs:element name="mod-cluster-config" type="mod-cluster-configType" minOccurs="0" maxOccurs="1"/>
      

      alternatively, we can use mod_cluster + mod_proxy_balancer or mod_cluster + mod_jk so that mod_cluster balances on 8080 and other tech(mod_proxy_balancer or mod_jk) balances on other port 37304.
      But this decision obviously not good: reverse loopback from servers(mgmt info with loadfactor of server) to balancer will manage balancing only for one port, not for both.

      Seems that mod_cluster absolutely not supports more than one connector balancing:

      Like mod_jk and mod_proxy_balancer, mod_cluster requires a connector in your server.xml to
      which to forward web requests. Unlike mod_jk and mod_proxy_balancer, mod_cluster is not
      confined to AJP, but can use HTTP as well. While AJP is generally faster, an HTTP connector
      can optionally be secured via SSL. If multiple possible connectors are defined in your server.xml,
      mod_cluster uses the following algorithm to choose between them:
      1. If an native (APR) AJP connector is available, use it.
      2. If an AJP connector is available, use it.
      3. Otherwise, choose the HTTP connector with the highest max threads.
      

      is this true?

      what is the best way to solve our problem?

      During more than 100 views no one answer :'(

      Now we have made a decision to use mod_proxy_balancer, but if it possible to refine mod_cluster subsystem, this will be greate. When it happens, we will jump to mod_cluster again

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              rhn-engineering-rhusar Radoslav Husar
              Reporter:
              kostd kostd kostd (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: