Search

15.5. Governance and S-RAMP in a Clustered Environment

download PDF
In a clustered environment, it is recommended to have a dedicated runtime governance server separate from the execution servers. In this case, all execution servers connect to the governance server via the runtime governance client.
Depending upon the load of the runtime governance server, it may be necessary to set up a cluster of governance servers as well. If you have a cluster of runtime governance servers, then they only need to connect to the same database instance. However, it is also possible to configure each runtime governance server to have its own S-RAMP database. The JBoss Fuse installer configures all components to use the same database by default so that runtime governance and S-RAMP share the same database instance. However, this is not mandatory.

Procedure 15.1. Configuring Governance and S-RAMP in a Clustered Environment

Perform the following steps on all servers in the cluster. Please note that this is just one of several possible configurations of governance components in a clustered environment.
  1. Add the <distributable/> entry inside the <web-app> element of the following web.xml files:
    • standalone/deployments/s-ramp-server.war/WEB-INF/web.xml
    • standalone/deployments/s-ramp-ui.war/WEB-INF/web.xml
    • standalone/deployments/dtgov.war/WEB-INF/web.xml
    • standalone/deployments/dtgov-ui.war/WEB-INF/web.xml
    • standalone/deployments/overlord-commons-idp.war/WEB-INF/web.xml
    • standalone/deployments/overlord-rtgov/gadget-web.war/WEB-INF/web.xml
    • standalone/deployments/overlord-rtgov/gadgets.war/WEB-INF/web.xml
    • standalone/deployments/overlord-rtgov/overlord-rtgov.war/WEB-INF/web.xml
  2. Add the <replication-config> entry:
    <replication-config>
      <cache-name>web/sso</cache-name>
    </replication-config>
    inside the <jboss-web> element of the following jboss-web.xml files:
    • standalone/deployments/s-ramp-server.war/WEB-INF/jboss-web.xml
    • standalone/deployments/s-ramp-ui.war/WEB-INF/jboss-web.xml
    • standalone/deployments/dtgov.war/WEB-INF/jboss-web.xml
    • standalone/deployments/dtgov-ui.war/WEB-INF/jboss-web.xml
    • standalone/deployments/overlord-commons-idp.war/WEB-INF/jboss-web.xml
    • standalone/deployments/overlord-rtgov/gadget-web.war/WEB-INF/jboss-web.xml
    • standalone/deployments/overlord-rtgov/gadgets.war/WEB-INF/jboss-web.xml
    • standalone/deployments/overlord-rtgov/overlord-rtgov.war/WEB-INF/jboss-web.xml
  3. Configure the ModeShape and Infinispan subsystems, and the jGroups TCP Stack in the standalone/configuration/standalone-ha.xml file as in the following code sample:
    <!-- Infinispan subsystem configuration -->
    
    <cache-container name="modeshape" module="org.modeshape"
      start="EAGER">
      <transport lock-timeout="60000" />
      <replicated-cache name="sramp" mode="SYNC" batching="true">
        <locking isolation="NONE" />
        <transaction mode="NON_XA" />
        <string-keyed-jdbc-store datasource="java:jboss/datasources/srampDS"
          passivation="false" purge="false">
          <string-keyed-table prefix="ispn_bucket">
            <id-column name="id" type="VARCHAR(500)" />
            <data-column name="datum" type="VARBINARY(60000)" />
            <timestamp-column name="version" type="BIGINT" />
          </string-keyed-table>
        </string-keyed-jdbc-store>
      </replicated-cache>
    </cache-container>
    <cache-container name="modeshape-binary-cache-container"
      aliases="modeshape-binary-cache" module="org.modeshape">
      <transport lock-timeout="60000" />
      <replicated-cache name="sramp-binary-fs" mode="SYNC"
        batching="true">
        <transaction mode="NON_XA" />
        <file-store relative-to="jboss.server.data.dir"
          path="modeshape/binary-store/sramp-binary-data-${jboss.node.name}"
          passivation="false" purge="false" />
      </replicated-cache>
    </cache-container>
    
    <!-- ModeShape subsystem configuration -->
    
    <subsystem xmlns="urn:jboss:domain:modeshape:1.0">
      <repository name="sramp" cache-name="sramp" cache-container="modeshape"
        security-domain="overlord-idp" anonymous-roles="readonly"
        cluster-name="sramp-cluster" cluster-stack="tcp">
        <indexing rebuild-upon-startup="if_missing" />
        <local-file-index-storage
          path="modeshape/clustered-repo/${jboss.node.name}_indexes" />
        <cache-binary-storage data-cache-name="binary-fs"
          metadata-cache-name="binary-fs-meta" cache-container="modeshape-binary-cache-container" />
      </repository>
    </subsystem>
    
    <!-- jgroups tcp stack configuration -->
    
    <subsystem xmlns="urn:jboss:domain:jgroups:1.1" default-stack="udp">
      ...
      <stack name="tcp">
      ...
        <protocol type="TCPPING">
          <property name="initial_hosts">0.0.0.0[7600],0.0.0.0[7600]</property>
          <property name="num_initial_members">2</property>
          <property name="port_range">0</property>
          <property name="timeout">2000</property>
        </protocol>
      </stack>
    </subsystem>
Red Hat logoGithubRedditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

© 2024 Red Hat, Inc.