diff --git a/.github/workflows/ci-build.yml b/.github/workflows/ci-build.yml
index e0a8e6c57..3524b5732 100644
--- a/.github/workflows/ci-build.yml
+++ b/.github/workflows/ci-build.yml
@@ -59,7 +59,7 @@ jobs:
uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6.1.0
with:
distribution: 'temurin'
- java-version: 17
+ java-version: 21
cache: 'maven'
- name: Build camel-kamelets
run: ./mvnw -V -ntp clean install
@@ -87,7 +87,7 @@ jobs:
uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6.1.0
with:
distribution: 'temurin'
- java-version: 17
+ java-version: 21
- name: Deploy to ASF Snapshots Repository
# Deploy both artifacts and sources (maybe required by Camel K)
run: |
diff --git a/.github/workflows/generate-sbom-main.yml b/.github/workflows/generate-sbom-main.yml
index 3eedf9552..f9e7b04a2 100644
--- a/.github/workflows/generate-sbom-main.yml
+++ b/.github/workflows/generate-sbom-main.yml
@@ -34,7 +34,7 @@ jobs:
timeout-minutes: 30
strategy:
matrix:
- java: [ '17' ]
+ java: [ '21' ]
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
diff --git a/.github/workflows/integration-tests.yaml b/.github/workflows/integration-tests.yaml
index bdd3d693f..d4144871e 100644
--- a/.github/workflows/integration-tests.yaml
+++ b/.github/workflows/integration-tests.yaml
@@ -56,12 +56,12 @@ jobs:
uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6.1.0
with:
distribution: 'temurin'
- # 25 for the Camel JBang launcher the tests run (//JAVA 21+ since CAMEL-23112), linked into JBang below instead
- # of downloaded (that download fails now and then); 17, listed last, stays the default for the Maven build and
- # the Citrus tests. With the Camel apps on 21 JiraIT failed in every run; it passed when JBang downloaded 27
+ # 25 for the Camel JBang launcher the tests run, linked into JBang below instead of downloaded (that download
+ # fails now and then); 21, listed last, stays the default for the Maven build (the Java baseline) and the Citrus
+ # tests. With the Camel apps on 21 JiraIT failed in every run; it passed when JBang downloaded 27
java-version: |
25
- 17
+ 21
cache: 'maven'
- name: Build Kamelet libraries
run: |
diff --git a/.github/workflows/java-tests.yaml b/.github/workflows/java-tests.yaml
index b90697d56..0b41659e9 100644
--- a/.github/workflows/java-tests.yaml
+++ b/.github/workflows/java-tests.yaml
@@ -46,7 +46,7 @@ jobs:
uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6.1.0
with:
distribution: 'temurin'
- java-version: 17
+ java-version: 21
cache: 'maven'
- name: Build catalog 1st Run
run: ./mvnw clean install -DskipTests -DskipITs
diff --git a/.github/workflows/main-push-regen.yaml b/.github/workflows/main-push-regen.yaml
index fb047545e..5691e9952 100644
--- a/.github/workflows/main-push-regen.yaml
+++ b/.github/workflows/main-push-regen.yaml
@@ -45,7 +45,7 @@ jobs:
uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6.1.0
with:
distribution: 'temurin'
- java-version: 17
+ java-version: 21
cache: 'maven'
- name: Build catalog 1st Run
run: ./mvnw clean install -DskipTests
diff --git a/.github/workflows/validate.yaml b/.github/workflows/validate.yaml
index 2a335448d..b22312075 100644
--- a/.github/workflows/validate.yaml
+++ b/.github/workflows/validate.yaml
@@ -54,7 +54,7 @@ jobs:
uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6.1.0
with:
distribution: 'temurin'
- java-version: 17
+ java-version: 21
cache: 'maven'
- name: Run Validator
run: |
diff --git a/AGENTS.md b/AGENTS.md
index 4d7014b0d..fb450b03d 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -10,7 +10,7 @@ Camel, Camel K, Camel Quarkus and Camel Spring Boot.
- Version: 4.20.0
- Camel: 4.20.0
-- Java: 17+
+- Java: 21+
- Build: Maven (`mvn verify`); Go is required for the `crds/` generator
- Issue tracker: GitHub — https://github.com/apache/camel-kamelets/issues
- Related repository: `apache/camel` (Camel core — the Kamelet **runtime**
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 20b17ce2b..3be03ec41 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -4,6 +4,10 @@
[Full Changelog](https://github.com/apache/camel-kamelets/compare/v4.22.1...HEAD)
+**Breaking changes:**
+
+- Raise the minimal Java version from 17 to 21, following Camel core \(CAMEL-22996\): the Kamelet libraries are now built for Java 21 and can no longer be used with Java 17
+
**Closed issues:**
- Remove camel:core from the Kamelet dependencies: every Camel runtime has it [\#3096](https://github.com/apache/camel-kamelets/issues/3096)
diff --git a/Jenkinsfile.deploy b/Jenkinsfile.deploy
index 76714d120..c79843646 100644
--- a/Jenkinsfile.deploy
+++ b/Jenkinsfile.deploy
@@ -19,7 +19,7 @@
def LOCAL_REPOSITORY = env.LOCAL_REPOSITORY ?: '/home/jenkins/jenkins-slave/maven-repositories/0'
def AGENT_LABEL = env.AGENT_LABEL ?: 'ubuntu'
-def JDK_NAME = env.JDK_NAME ?: 'jdk_17_latest'
+def JDK_NAME = env.JDK_NAME ?: 'jdk_21_latest'
def MAVEN_PARAMS = '-U -B -e -fae -V -Dmaven.repo.local=/home/jenkins/.m2/repository -Dmaven.compiler.fork=true'
diff --git a/Jenkinsfile.ppc64le b/Jenkinsfile.ppc64le
index 9bc4c280c..3c7c9619e 100644
--- a/Jenkinsfile.ppc64le
+++ b/Jenkinsfile.ppc64le
@@ -19,7 +19,7 @@
def LOCAL_REPOSITORY = env.LOCAL_REPOSITORY ?: '/home/jenkins/jenkins-slave/maven-repositories/0'
def AGENT_LABEL = env.AGENT_LABEL ?: 'power9'
-def JDK_NAME = env.JDK_NAME ?: 'jdk_17_latest'
+def JDK_NAME = env.JDK_NAME ?: 'jdk_21_latest'
def MAVEN_PARAMS = '-U -B -e -fae -V -Dmaven.repo.local=/home/jenkins/.m2/repository -Dmaven.compiler.fork=true'
diff --git a/jitpack.yml b/jitpack.yml
index efde7bf25..727c9abd3 100644
--- a/jitpack.yml
+++ b/jitpack.yml
@@ -1,2 +1,2 @@
jdk:
- - openjdk17
+ - openjdk21
diff --git a/library/camel-kamelets-catalog/pom.xml b/library/camel-kamelets-catalog/pom.xml
index 08796eca4..e6a9cb0c3 100644
--- a/library/camel-kamelets-catalog/pom.xml
+++ b/library/camel-kamelets-catalog/pom.xml
@@ -25,8 +25,8 @@
org.apache.maven.plugins
maven-compiler-plugin
- 17
- 17
+ 21
+ 21
diff --git a/library/camel-kamelets-crds/pom.xml b/library/camel-kamelets-crds/pom.xml
index 02383ca7c..85a332bed 100644
--- a/library/camel-kamelets-crds/pom.xml
+++ b/library/camel-kamelets-crds/pom.xml
@@ -33,9 +33,9 @@
UTF-8
- 17
- 17
- 17
+ 21
+ 21
+ 21
8.0.0
3.5.0
diff --git a/library/kamelets-maven-plugin/pom.xml b/library/kamelets-maven-plugin/pom.xml
index 1e90cb74b..84c502c51 100644
--- a/library/kamelets-maven-plugin/pom.xml
+++ b/library/kamelets-maven-plugin/pom.xml
@@ -120,8 +120,8 @@
org.apache.maven.plugins
maven-compiler-plugin
- 17
- 17
+ 21
+ 21
diff --git a/pom.xml b/pom.xml
index da45971bc..50ca776a7 100644
--- a/pom.xml
+++ b/pom.xml
@@ -43,9 +43,9 @@
- 17
- 17
- 17
+ 21
+ 21
+ 21
false
UTF-8
@@ -301,8 +301,8 @@
org.apache.maven.plugins
maven-compiler-plugin
- 17
- 17
+ 21
+ 21
diff --git a/tests/camel-kamelets-itest/README.md b/tests/camel-kamelets-itest/README.md
index 4d522f8d3..ce8d2b8f9 100644
--- a/tests/camel-kamelets-itest/README.md
+++ b/tests/camel-kamelets-itest/README.md
@@ -3,7 +3,7 @@
This folder contains a suite of integration tests for Kamelets
You need the following tools to run the tests:
-- Java 17
+- Java 21
- [JBang](https://www.jbang.dev/)
- [Camel JBang](https://camel.apache.org/manual/camel-jbang.html)
- [Citrus JBang App](https://citrusframework.org/citrus/reference/html/index.html#runtime-jbang-install)