Chapter 4. Preparing a Red Hat JBoss BRMS Project Repository for OpenShift


4.1. Stateless Sessions

Note

The Red Hat JBoss BRMS project must be configured to be stateless. OpenShift does not support stateful sessions on KIE servers.

A Red Hat JBoss BRMS project running in Red Hat JBoss BRMS could be configured to be stateless of stateful. A project that has already been deployed on a Decision Server xPaaS image will be configured to be stateless.

Ensuring a Red Hat JBoss BRMS project is stateless:
The Knowledge Session (in the web console, Open Project Editor Project Settings Knowledge bases and sessions) displays whether the session is configured to be Stateless.

4.2. Configuring the Project Remote Repository

The project must be configured to use a remote repository so that Red Hat JBoss BRMS can push changes and OpenShift can pull the repository to build the application.

In the application repository files:

  1. The pom.xml must be configured to use a remote repository so that OpenShift can access it.

    ...
    <distributionManagement>
      <repository>
        <id>deployment</id>
        <name>OpenShift Maven repo</name>
        <url>http://maven.example/deployment/filepath/</url>
      </repository>
    
      <snapshotRepository>
        <id>deployment</id>
        <name>OpenShift Maven repo</name>
        <url>http://maven.example/snapshots/filepath/</url>
      </snapshotRepository>
    </distributionManagement>
    ...

    For more information, see the Red Hat JBoss BRMS Administration and Configuration Guide.

  2. The configuration/settings.xml file must have the remote repository defined so that OpenShift can download the application artifacts.

    ...
    <profiles>
      <profile>
        <id>openshift-mirror-repositories</id>
        <repositories>
          <repository>
            <id>openshift-mirror</id>
            <url>http://maven.example/public/filepath/</url>
          </repository>
        </repositories>
    
        <pluginRepositories>
          <pluginRepository>
            <id>openshift-mirror</id>
            <url>http://maven.example/public/filepath/</url>
          </pluginRepository>
        </pluginRepositories>
      </profile>
    </profiles>
    ...

    For more information, see the Red Hat JBoss BRMS Installation Guide.

  3. The hidden .s2i/environment file defines the KIE container deployment, including which KIE jars to use and the location from which to retrieve them. When OpenShift deploys the built image, the pod name is derived from the deployment alias defined in this file:

    KIE_CONTAINER_DEPLOYMENT=<alias>=<group_id>:<artifact_id>:<version>

    For example:

    KIE_CONTAINER_DEPLOYMENT=RulesTest=com.example.openshift:example_workflow:1.0
    Note

    Defining the container name here is necessary because the default behavior of the KIE server is to search for the default stateful session and fail if it does not find one.

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.