Fix GitHub Actions Java compilation failures by updating Java distribution#1
Closed
Copilot wants to merge 4 commits into
Closed
Fix GitHub Actions Java compilation failures by updating Java distribution#1Copilot wants to merge 4 commits into
Copilot wants to merge 4 commits into
Conversation
Co-authored-by: husakki <81704101+husakki@users.noreply.github.com>
Co-authored-by: husakki <81704101+husakki@users.noreply.github.com>
Co-authored-by: husakki <81704101+husakki@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Can you take a look why the github aciton is failing and fix the issue?
Fix GitHub Actions Java compilation failures by updating Java distribution
Sep 25, 2025
Owner
|
@copilot What caused all those local directories to be inside the repository, what was the mistake on my end? |
Contributor
Author
The issue was caused by the
The mistake was not having |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The GitHub Actions workflows were failing with compilation errors:
This was preventing both the CI/CD pipeline and release workflows from functioning properly.
Root Cause
The issue was that the GitHub Actions workflows were configured to use the
adoptJava distribution, which was discontinued and doesn't support Java 21. The project's Maven configuration specifies Java 21 as both source and target compilation version across all modules.Solution
Updated all GitHub Actions workflows to use the
temurindistribution instead ofadopt:In
.github/workflows/maven.yml(both build and test jobs):In
.github/workflows/release.yml:Additional Improvements
3.1.5to thespring-boot-maven-plugininuse-api/pom.xmlto eliminate build warnings.gitignoreto excludeuse-api/targetdirectory to prevent build artifacts from being committedVerification
BUILD SUCCESSfor all 5 modulesImpact
This fix resolves the CI/CD pipeline failures and enables:
The workflows should now pass successfully with Java 21 support.
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
esm.ubuntu.com/usr/lib/apt/methods/https(dns block)If you need me to access, download, or install something from one of these locations, you can either:
Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.