Subscribe to the feed

 

If you're a Java developer looking for a powerful platform to build highly transactional and scalable applications, you've come to the right place.

In this article, we'll highlight the benefits of the JBoss Enterprise Application Platform and provide a detailed step-by-step guide on deploying and managing it effortlessly on OpenShift using the EAP Operator.

So, let's dive in and unlock the true potential of your Java applications!

What Is Red Hat JBoss Enterprise Application Platform (JBoss EAP)?

JBoss EAP is an open-source platform for building highly transactional and scalable Java applications. By combining Jakarta EE specifications with modern technologies like Eclipse MicroProfile, it enables the transformation of traditional Java EE applications into cloud-native architectures.

It provides a comprehensive set of tools to develop, deploy, and manage enterprise Java applications in various environments, including on-premises, virtual setups, and private/public/hybrid clouds.

Based on the widely used open-source project WildFly, JBoss EAP offers everything needed to build, run, and manage enterprise Java applications effectively.

What Is the EAP Operator?

Based on the open source upstream project, wildfly-operator, the EAP Operator is a software component that facilitates the deployment and management of JBoss EAP on container orchestration platforms like OpenShift. The operator acts as an automated management tool, simplifying the process of provisioning, scaling, and updating JBoss EAP applications.

What Is an Operator?

Operators, introduced by the CoreOS Linux team in 2016, simplify application management within Kubernetes. They are software extensions that treat applications as single objects, utilizing custom resources to manage applications and their components.

Instead of dealing with individual primitives, Operators provide specific adjustments tailored to the application that automate installation, configuration, and ongoing maintenance tasks.

Acting as controllers for packaging, managing, and deploying applications on Kubernetes, Operators utilize Custom Resource Definitions (CRDs) to define desired configurations. They continuously reconcile the actual state of the application with the desired state defined by the CRD, enabling automatic scaling, updates, and restarts.

Operators extend Kubernetes capabilities, performing complex functions beyond the scope of native Kubernetes operations.

What Are the Use Cases for the JBoss EAP Operator?

The EAP Operator serves various use cases for organizations looking to deploy and manage multiple instances of the JBoss EAP Java application instances within a Kubernetes cluster.

Let's explore a few scenarios where the EAP Operator shines:

  • Simplifies management: The EAP Operator can create, configure, manage, and seamlessly upgrade instances of complex stateful applications. It abstracts away the complexities of manual configuration, making management a breeze.
  • Enables efficient scaling and updates: Effortlessly scale your JBoss EAP Java application instances based on demand. It helps your applications handle increased traffic by automatically provisioning additional resources. Furthermore, the Operator facilitates seamless updates, enabling you to roll out new features and bug fixes without downtime.
  • Offers safe transaction recovery: The EAP Operator provides safe transaction recovery in your application cluster by verifying all transactions are completed before scaling down the replicas and marking a pod as clean for termination. The EAP Operator uses StatefulSets to handle EJB remoting and transaction recovery processing appropriately. The StatefulSet provides persistent storage and network hostname stability even after pods are restarted.

Installation Steps

Let's walk through the steps to install the EAP Operator on your OpenShift 4.x Cluster and deploy your first example application:

Step 1: Create a project

  • Log in to your OpenShift cluster as the Administrator and go to Home > Projects.
  • Create a new project and give it a name, such as wildfly.

Step 2: Install JBoss EAP from OperatorHub

  • Navigate to Operators > OperatorHub.
  • Search for "jboss eap" (provided by Red Hat) and install it.
  • Choose "All namespaces on the cluster" as the installation mode (defaults to"openshift-operators" namespace).

Step 3: Deploy your first example application

  • Switch to the "wildfly" namespace: oc project wildfly
  • Utilize the following Helm Chart to build the JBoss EAP application image using Source-to-Image (S2I) on OpenShift:
cat <<EOF > helm.yaml
build:
  uri: https://github.com/jboss-eap-up-and-running/eap7-getting-started
deploy:
  enabled: false
EOF
helm install eap7-app -f ./helm.yaml --repo https://charts.openshift.io redhat-eap74

  • Create the application by applying the following YAML configuration using the wildflyserver custom resource:
cat <<EOF | oc apply -f -
apiVersion: wildfly.org/v1alpha1
kind: WildFlyServer
metadata:
  name: eap7-app
spec:
  applicationImage: eap7-app:latest
  replicas: 1
EOF

 

Step 4: Access the application website

  • The Operator automatically generates routes for you. Simply copy and paste the route into your web browser.
  • To view the routes, run: oc get route

Wrap up

By following these steps, you can successfully install the EAP Operator on your OpenShift cluster and deploy your first example application.

You can find more examples for experimentation in this repository.

The EAP Operator empowers you to harness the full potential of JBoss EAP, simplifying management, enabling efficient scaling, and ensuring safe transaction recovery in your application cluster.

Start exploring the possibilities and unlock the power of your Java applications with the EAP Operator.


About the author

Specializing in end-to-end infrastructure to deployment of containerized applications, I am a Cloud Infrastructure Engineer with extensive experience in Kubernetes native application design and optimization.

My passion for technology drives me to continuously explore cutting-edge tools and practices, enabling me to design and implement innovative solutions that optimize performance and user experience.

With a keen eye for detail and a commitment to excellence, I thrive on turning challenging problems into seamless, efficient solutions.

Read full bio

Browse by channel

automation icon

Automation

The latest on IT automation for tech, teams, and environments

AI icon

Artificial intelligence

Updates on the platforms that free customers to run AI workloads anywhere

open hybrid cloud icon

Open hybrid cloud

Explore how we build a more flexible future with hybrid cloud

security icon

Security

The latest on how we reduce risks across environments and technologies

edge icon

Edge computing

Updates on the platforms that simplify operations at the edge

Infrastructure icon

Infrastructure

The latest on the world’s leading enterprise Linux platform

application development icon

Applications

Inside our solutions to the toughest application challenges

Original series icon

Original shows

Entertaining stories from the makers and leaders in enterprise tech