Skip to content

Commit 721bb3d

Browse files
ruhan1claude
andauthored
Pin Maven to 3.8.8 for Java 11 compatibility (#104)
* Pin GitHub Actions runners to ubuntu-22.04 The ubuntu-latest runner switched from Ubuntu 22.04 to Ubuntu 24.04 on Jan 17, 2025, which includes Maven 3.9.12. Maven 3.9.6+ enforces stricter Java prerequisites for plugins. While quarkus-maven-plugin 3.6.9 requires Java 17 to execute, our codebase uses Datastax Cassandra Driver 3.7.2 (from path-mapped-storage) which only supports Java 8-11. Upgrading to Datastax Driver 4.x would be a major migration. Pinning to ubuntu-22.04 keeps us on an older Maven version that doesn't enforce the plugin Java requirement as strictly, allowing builds to continue on Java 11. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> * Install Maven 3.8.8 explicitly to avoid Java 17 requirement Maven 3.9.0+ enforces stricter Java prerequisites for plugins. The quarkus-maven-plugin:3.6.9 requires Java 17 to execute when used with Maven 3.9.x, even though it's compiled for Java 11. Maven 3.8.8 (last pre-3.9 version) doesn't enforce this check, allowing the build to work with Java 11. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent 788dc8f commit 721bb3d

2 files changed

Lines changed: 12 additions & 2 deletions

File tree

.github/workflows/merge-build.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
publish-snapshot:
2626
name: publish to oss sonatype & push image
2727

28-
runs-on: ubuntu-latest
28+
runs-on: ubuntu-22.04
2929

3030
permissions:
3131
contents: read
@@ -44,6 +44,11 @@ jobs:
4444
architecture: x64
4545
java-version: 11
4646

47+
- name: Set up Maven
48+
uses: stCarolas/setup-maven@v4.5
49+
with:
50+
maven-version: 3.8.8
51+
4752
- name: maven-settings-xml-action
4853
uses: whelk-io/maven-settings-xml-action@v14
4954
if: ${{ github.event.repository.fork == false }}

.github/workflows/pr-build.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ on: [pull_request]
2424
jobs:
2525
build:
2626

27-
runs-on: ubuntu-latest
27+
runs-on: ubuntu-22.04
2828

2929
steps:
3030
- uses: actions/checkout@v2
@@ -35,6 +35,11 @@ jobs:
3535
java-version: '11'
3636
distribution: 'adopt'
3737

38+
- name: Set up Maven
39+
uses: stCarolas/setup-maven@v4.5
40+
with:
41+
maven-version: 3.8.8
42+
3843
- name: maven-settings-xml-action
3944
uses: whelk-io/maven-settings-xml-action@v14
4045
with:

0 commit comments

Comments
 (0)