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

[MNG-8376] Exit with a nicer error message when running on JDK < 17 #1916

Merged
merged 4 commits into from
Nov 18, 2024

Conversation

gnodet
Copy link
Contributor

@gnodet gnodet commented Nov 16, 2024

Needs to be tested on windows, or maybe just add an IT ?

@michael-o
Copy link
Member

michael-o commented Nov 17, 2024

Needs to be tested on windows, or maybe just add an IT ?

Why not, sounds reasonable...via toolchains?

@slawekjaranowski
Copy link
Member

We assume thet user have awk ....
What do you think to create a simple class like:

public class CheckJavaVersion {
    public static void main(String[] args) {
        if (Double.parseDouble(System.getProperty("java.vm.specification.version")) < 17.0) {
            System.exit(2);
        }
    }
}

compile with target 8, put in bin directory

it will be easy to execute and check statu code of execution

@gnodet
Copy link
Contributor Author

gnodet commented Nov 17, 2024

We assume thet user have awk .... What do you think to create a simple class like:

public class CheckJavaVersion {
    public static void main(String[] args) {
        if (Double.parseDouble(System.getProperty("java.vm.specification.version")) < 17.0) {
            System.exit(2);
        }
    }
}

compile with target 8, put in bin directory

it will be easy to execute and check statu code of execution

I just changed the script to simply rely on java to verify that the argument can be used.

@michael-o michael-o removed their request for review November 18, 2024 09:40
@gnodet gnodet added this to the 4.0.0-rc-1 milestone Nov 18, 2024
@gnodet gnodet merged commit bad1387 into apache:master Nov 18, 2024
13 checks passed
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.

5 participants