Skip to content

Revert "Add arguments to server and console script to prevent warnings"#2699

Merged
robfrank merged 1 commit intomainfrom
revert-2698-main
Oct 24, 2025
Merged

Revert "Add arguments to server and console script to prevent warnings"#2699
robfrank merged 1 commit intomainfrom
revert-2698-main

Conversation

@robfrank
Copy link
Collaborator

Reverts #2698

@robfrank robfrank merged commit 011c1ea into main Oct 24, 2025
5 of 8 checks passed
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @robfrank, 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!

This pull request is a direct revert of a previous change (PR #2698) that introduced specific JVM arguments to the console.sh and server.sh scripts, primarily to suppress warnings. By reverting these changes, the PR restores the scripts to their prior state, removing the previously added --enable-native-access and --sun-misc-unsafe-memory-access flags. Additionally, the console.sh script now explicitly includes --illegal-access=deny, which clarifies the desired behavior regarding reflective access to internal APIs.

Highlights

  • Revert of Previous Changes: This pull request fully reverts the modifications introduced in Add arguments to server and console script to prevent warnings #2698, which had aimed to prevent JVM warnings by adding specific arguments to startup scripts.
  • JVM Argument Removal: The --enable-native-access=ALL-UNNAMED argument has been removed from both console.sh and server.sh.
  • Specific Argument Removal in Server Script: The --sun-misc-unsafe-memory-access=allow argument has been removed from the server.sh script.
  • New JVM Argument in Console Script: The --illegal-access=deny argument has been added to the console.sh script.
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 by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

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 pull request 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 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. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

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.

Footnotes

  1. 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.

@robfrank robfrank deleted the revert-2698-main branch October 24, 2025 11:18
@mergify
Copy link
Contributor

mergify bot commented Oct 24, 2025

🧪 CI Insights

Here's what we observed from your CI run for c3a5675.

🟢 All jobs passed!

But CI Insights is watching 👀

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a 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 reverts changes that added specific JVM arguments to the server.sh and console.sh startup scripts. While the changes in server.sh appear to be a clean revert, the console.sh script introduces a new --illegal-access=deny flag. My review focuses on the potential issues this new flag can cause, particularly with newer JDK versions, and the inconsistency it creates with the Windows startup script. I have suggested removing this flag to align with the intent of the revert.

Comment on lines +62 to +63
-Dfile.encoding=UTF8 \
--illegal-access=deny"
Copy link
Contributor

Choose a reason for hiding this comment

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

high

The addition of --illegal-access=deny is concerning. This flag is not recognized in JDK 17 and later, and will cause the JVM to fail to start. For JDK 9-15, it changes the default behavior which might cause unexpected IllegalAccessException if the application or its dependencies rely on reflective access to internal APIs.

Since this PR is a revert, it seems this line may have been added unintentionally. The corresponding console.bat file does not include this flag, leading to an inconsistency between platforms.

To make this a clean revert and maintain consistency, I suggest removing the added flag.

Suggested change
-Dfile.encoding=UTF8 \
--illegal-access=deny"
-Dfile.encoding=UTF8"

@codacy-production
Copy link

Coverage summary from Codacy

See diff coverage on Codacy

Coverage variation Diff coverage
-0.23%
Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (428fe0d) 73090 46548 63.69%
Head commit (c3a5675) 73090 (+0) 46378 (-170) 63.45% (-0.23%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#2699) 0 0 ∅ (not applicable)

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

See your quality gate settings    Change summary preferences

robfrank added a commit that referenced this pull request Nov 10, 2025
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.

1 participant