Building Apache Camel - linux-on-ibm-z/docs GitHub Wiki

Building Apache Camel

General Notes:

  • When following the steps below please use a standard permission user unless otherwise specified.
  • A directory /<source_root>/ will be referred to in these instructions, this is a temporary writable directory anywhere you'd like to place it.

Apache Camel binary releases are available here. To use these binaries, different Java flavours can be installed on the mentioned distributions.

Note: Apache Camel (v4.4.1) was verified at the time of creation of these instructions

1. Install Java

   export SOURCE_ROOT=/<source_root>/
  • RHEL (7.8, 7.9, 8.6, 8.8, 8.9, 9.0, 9.2, 9.3)

    • With OpenJDK 17:

      sudo yum install -y java-17-openjdk java-17-openjdk-devel  # except RHEL 7.x
      
    • With IBM Semeru Runtime (previously known as AdoptOpenJDK openj9):

      sudo yum install -y wget tar
      
      • Download and install IBM Semeru Runtime (Java 17) from here.
    • With Eclipse Adoptium Temurin Runtime (previously known as AdoptOpenJDK hotspot)

      sudo yum install -y wget tar
      
      • Download and install Eclipse Adoptium Temurin Runtime (Java 17) from here.
  • SLES (12 SP5, 15 SP5)

    • With OpenJDK 17:

      sudo zypper install -y java-17-openjdk java-17-openjdk-devel  # except SLES 12 SP5
      
    • With IBM Semeru Runtime (previously known as AdoptOpenJDK openj9):

      sudo zypper install -y wget tar gzip
      
      • Download and install IBM Semeru Runtime (Java 17) from here.
    • With Eclipse Adoptium Temurin Runtime (previously known as AdoptOpenJDK hotspot)

      sudo zypper install -y wget tar gzip
      
      • Download and install Eclipse Adoptium Temurin Runtime (Java 17) from here.
  • Ubuntu (20.04, 22.04, 23.10)

    • With OpenJDK 17

      sudo apt-get update
      sudo apt-get install -y  openjdk-17-jdk
      
    • With IBM Semeru Runtime (previously known as AdoptOpenJDK openj9):

      sudo apt-get -y install wget tar
      
      • Download and install IBM Semeru Runtime (Java 17) from here.
    • With Eclipse Adoptium Temurin Runtime (previously known as AdoptOpenJDK hotspot)

      sudo apt-get -y install wget tar
      
      • Download and install IBM Semeru Runtime (Java 17) from here.

Note: Eclipse Adoptium Temurin Runtime Version jdk-17.0.7+7, IBM Semeru Runtime Version jdk-17.0.6+10 and OpenJDK 17 (except RHEL 7.x and SLES 12 SP5) were used for verifying these instructions.

2. Set environment variables

export JAVA_HOME=<path to java>
export PATH=$JAVA_HOME/bin:$PATH

3. Use Camel jars

To use the Camel binary in your Apache Maven pom.xml, import the Camel Bill of Materials (BOM) and then include the camel-core and any other components needed as mentioned here. There are also few examples available for reference.

Note: Apache Component references provides various references that offers services for messaging, sending data, notifications and various other services that can not only resolve easy messaging and transferring data but also provide securing of data. However few components such as Deep Java Library and Kudu are not supported on s390x. Java Flight Recorder, GraalVM Polyglot are not available in IBM Semeru Runtime (OpenJ9). Components using Hadoop (e.g. HDFS) will fail with Semeru and fix will be available in next Hadoop release (a workaround is available for current Hadoop release).

If you want to build Camel from source, refer official documentation. In this documentation mvn clean install runs all the unit tests. Few components tests requires Docker images which are currently not available for s390x and will fail.

References: