Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: Use consistent java versions using sdkman #28868

Merged

Conversation

spbolton
Copy link
Contributor

@spbolton spbolton commented Jun 13, 2024

Proposed Changes

  • Change java base image to use sdkman to get java version. Use SDKMAN_JAVA_VERSION build arg to specify SDKMAN version and implementation.
  • Create manual workflow specifically for creating java base image based upon SDKMAN version string being tagged and pushed with that version.
  • Modify maven to pick up version specified in ~/.sdkmanrc and use that by default to specify which upstream java base image to used.
  • Cleanup places where java version is specified in maven pom files to default to a single location in parent/pom.xml. Set default value in environments/environment.properties so it can be modified locally be developers easily and changed in one place. setting java.compat.version=11
  • Use independent version for compatibility of build allowing Java 21 to be upgraded to but still allowing plugins to be build with Java 11 with easy switch later.
  • Cleanup DockerFiles with some AI help.

Note:

  • This change does not actually update to java 21 yet. We should do internal test to upgrade to latest point release of java 11 first. e.g. 11.0.22-ms -> 11.0.23-ms
  • This change does not modify the version used in the ci build workflows. We will follow up a change to enable consistent use of the .sdkmanrc in the workflows after this PR.

@spbolton spbolton linked an issue Jun 13, 2024 that may be closed by this pull request
4 tasks
@spbolton spbolton force-pushed the issue-27998-task-update-workflow-to-support-any-java-version branch 5 times, most recently from ae0ed22 to 50b57c1 Compare June 17, 2024 11:17
@spbolton spbolton force-pushed the issue-27998-task-update-workflow-to-support-any-java-version branch from 50b57c1 to 6dd0970 Compare June 17, 2024 11:18
@spbolton spbolton marked this pull request as ready for review June 17, 2024 11:18
@spbolton spbolton requested a review from a team as a code owner June 17, 2024 11:18
@spbolton spbolton enabled auto-merge June 17, 2024 11:26
Copy link

Copy link
Contributor

@wezell wezell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Back to SDK man we go!

@spbolton spbolton added this pull request to the merge queue Jun 17, 2024
Merged via the queue into master with commit 1114b54 Jun 17, 2024
27 checks passed
@spbolton spbolton deleted the issue-27998-task-update-workflow-to-support-any-java-version branch June 17, 2024 23:34
oidacra pushed a commit that referenced this pull request Jun 26, 2024
### Proposed Changes
* Change java base image to use sdkman to get java version. Use
SDKMAN_JAVA_VERSION build arg to specify SDKMAN version and
implementation.
* Create manual workflow specifically for creating java base image based
upon SDKMAN version string being tagged and pushed with that version.
* Modify maven to pick up version specified in ~/.sdkmanrc and use that
by default to specify which upstream java base image to used.
* Cleanup places where java version is specified in maven pom files to
default to a single location in parent/pom.xml. Set default value in
environments/environment.properties so it can be modified locally be
developers easily and changed in one place. setting
java.compat.version=11
* Use independent version for compatibility of build allowing Java 21 to
be upgraded to but still allowing plugins to be build with Java 11 with
easy switch later.
* Cleanup DockerFiles with some AI help.


Note: 
* This change does not actually update to java 21 yet. We should do
internal test to upgrade to latest point release of java 11 first. e.g.
11.0.22-ms -> 11.0.23-ms
* This change does not modify the version used in the ci build
workflows. We will follow up a change to enable consistent use of the
.sdkmanrc in the workflows after this PR.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Task: Update Workflow to Support Any Java Version Using SDKMAN
3 participants