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

[improve] A more universal method to detect java8 #4198

Closed
wants to merge 1 commit into from

Commits on Feb 4, 2024

  1. The current bookkeeper installation package's scripts in the bin dire…

    …ctory depend on JAVA_HOME to detect whether the current Java runtime environment is Java 8. However, in some deployment scenarios, the system does not configure the JAVA_HOME environment variable. If Java 11 or a higher version is installed, running the script will result in the following error:
    
    ```
    # yum install java-11-openjdk-devel
    # bin/bookkeeper shell
    JAVA_HOME not set, using java from PATH. (/usr/bin/java)
    OpenJDK 64-Bit Server VM warning: Option AggressiveOpts was deprecated in version 11.0 and will likely be removed in a future release.
    Unrecognized VM option 'PrintGCApplicationStoppedTime'
    Error: Could not create the Java Virtual Machine.
    Error: A fatal exception has occurred. Program will exit.
    ```
    
    This patch provides a more universal method to detect whether the runtime environment is Java 8, while avoiding the restriction of forcing users to set the JAVA_HOME variable.
    Shawyeok committed Feb 4, 2024
    Configuration menu
    Copy the full SHA
    f4ef62d View commit details
    Browse the repository at this point in the history