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

potential failure of activation when JDK <11 is also installed #1621

Closed
Eskibear opened this issue Sep 17, 2020 · 2 comments · Fixed by #1701
Closed

potential failure of activation when JDK <11 is also installed #1621

Eskibear opened this issue Sep 17, 2020 · 2 comments · Fixed by #1701
Assignees

Comments

@Eskibear
Copy link
Contributor

Context

It simply finds the first available JDK in below order:

Steps

Now since it requires JDK 11+, a broken case is:

  • both JDK 8 and JDK 11 installed
  • java.home not set (for most new users)
  • JAVA_HOME points to JDK 8

It will pick JDK 8, and request users to install JDK 11+.

Possible solution

Add new options to find-java-home, like minVersion (requires the library to check version), or request the library to return all possible java homes.

@Eskibear
Copy link
Contributor Author

ultimately it would be perfect to provide new APIs in upstream, tracked in jsdevel/node-find-java-home#28

@testforstephen
Copy link
Collaborator

A good finding, looks like this is not a rare case.

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 a pull request may close this issue.

2 participants