-
Notifications
You must be signed in to change notification settings - Fork 6.5k
chore(deps): update openjdk docker tag to v11 - autoclosed #13379
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
chore(deps): update openjdk docker tag to v11 - autoclosed #13379
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @renovate-bot, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
Summary of Changes
Hello! Gemini, your friendly code-assist bot, is here to provide a summary of this pull request. This PR, authored by renovate-bot, aims to update the version of OpenJDK used in the dataflow/snippets/Dockerfile
. Specifically, it proposes upgrading the base image for copying the JRE from OpenJDK 8 to OpenJDK 11. This is a routine dependency update managed by Renovate to keep the project's dependencies current.
Highlights
- Dependency Update: The primary goal of this PR is to update the OpenJDK dependency used within a Dockerfile.
- OpenJDK Version Bump: The update changes the OpenJDK version from
8-jre-slim
to11.0.16-jre-slim
. - Dockerfile Change: The change is confined to a single line in the
dataflow/snippets/Dockerfile
.
Changelog
- dataflow/snippets/Dockerfile
- Updated the
COPY --from
instruction to use theopenjdk:11.0.16-jre-slim
image tag instead ofopenjdk:8-jre-slim
(Line 24).
- Updated the
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command>
or @gemini-code-assist <command>
. Below is a summary of the supported commands.
Feature | Command | Description |
---|---|---|
Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/
folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist is currently in preview and may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments to provide feedback.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Old Java eight, now gone,
Eleven steps onto the stage,
Docker builds move on.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request, generated by Mend Renovate, aims to update the OpenJDK version used in the Dockerfile from 8 to 11. While updating dependencies is generally good, there's a critical issue with how the JRE is being copied from the new base image, and a related maintainability concern with the destination path.
Summary of Findings
- Incorrect JRE source path in Dockerfile: The
COPY
command indataflow/snippets/Dockerfile
(line 24) uses/usr/local/openjdk-8
as the source path for JRE files from theopenjdk:11.0.16-jre-slim
image. This is likely incorrect, as OpenJDK 11 images typically store JRE files at/usr/local/openjdk-11
. This could result in the JRE not being installed, which is a critical issue. - Misleading JRE destination path in Dockerfile: The
COPY
command (line 24) installs Java 11 into a directory named/usr/local/openjdk-8
. This is misleading and inconsistent. For better maintainability, the destination path should reflect the Java version (e.g.,/usr/local/openjdk-11
). This would also require updates toJAVA_HOME
(line 25) andupdate-alternatives
(line 26).
Merge Readiness
This pull request has a critical issue regarding the JRE installation path in the Dockerfile. The source path for copying the JRE from the openjdk:11.0.16-jre-slim
image appears to be incorrect, which could lead to a broken JRE setup. Additionally, the destination path is misleading.
I recommend that these issues, particularly the critical source path error, be addressed before merging. The suggested code change for line 24 should resolve the immediate problem on that line, but related changes to JAVA_HOME
and update-alternatives
on subsequent lines (not in this diff) should also be considered for full consistency.
As an AI reviewer, I am not authorized to approve pull requests. Please ensure further review and approval by authorized maintainers after addressing the identified issues.
@@ -21,7 +21,7 @@ | |||
FROM python:3.12-slim | |||
|
|||
# Install JRE | |||
COPY --from=openjdk:8-jre-slim /usr/local/openjdk-8 /usr/local/openjdk-8 | |||
COPY --from=openjdk:11.0.16-jre-slim /usr/local/openjdk-8 /usr/local/openjdk-8 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are a couple of concerns with this line:
-
(Critical) Is
/usr/local/openjdk-8
the correct source path for JRE 11 files within theopenjdk:11.0.16-jre-slim
image? TheJAVA_HOME
(and thus the typical installation path) foropenjdk:11.0.16-jre-slim
is/usr/local/openjdk-11
. If/usr/local/openjdk-8
does not exist or does not contain the JRE in the source image, thisCOPY
command will fail to install Java correctly, potentially leading to runtime errors for applications depending on JRE. -
(Medium) Using
/usr/local/openjdk-8
as the destination path for Java 11 is misleading and harms maintainability. It would be clearer to use a path that reflects the actual Java version being installed, such as/usr/local/openjdk-11
.
If the destination path is updated to /usr/local/openjdk-11
, please also ensure that JAVA_HOME
on line 25 and the path in the update-alternatives
command on line 26 are updated accordingly to /usr/local/openjdk-11
for consistency. (These lines are not part of the current diff, so they would need to be changed separately.)
I suggest updating this line to use the correct source path for Java 11 and a version-appropriate destination path.
COPY --from=openjdk:11.0.16-jre-slim /usr/local/openjdk-11 /usr/local/openjdk-11
This PR contains the following updates:
8-jre-slim
->11.0.16-jre-slim
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Never, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.