-
Notifications
You must be signed in to change notification settings - Fork 439
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
java.configuration.runtimes not working #2625
Comments
Do you mean that in Have you tried to click |
I've done everything I can do - change the version, reboot, etc, but I cannot configure JDK version I want.
Please let me know if there's anything I can try more. |
|
Might be the same as #2525, which is an upstream issue caused by m2e: eclipse-m2e/m2e-core#842. Is your project contains multiple profiles which specifies different JDKs? |
No, not really. What I remember clearly is, |
The m2e issue eclipse-m2e/m2e-core#842 is related to a different source level defined in the test scope. The current m2e might ignore this configuration and use that in compile scope only. @nunojun is your project has different source level in compile scope and test scope? Besides, IIUC |
@CsCherrYY Thank you. When I create a simple java code w/ a main method using JDK11 apis, it works as below. If I open a maven project created by Spring Initializr, it also finds JDK11 as expected. However, once I open my project, it goes to This is my settings.json for
Please let me know if you need any other information. (e.g. pom.xml) |
Please attach pom.xml. |
@snjeza I attached pom.xml and this is the way to reproduce it.
|
@nunojun Could you try to change the enforcer configuration rule:
to
|
Thank you, @snjeza . It works after I change the |
I think this is an upstream issue in m2e |
I have a similar issue. For me one way to resolve that is to change the |
[provide a description of the issue]
Environment
Steps To Reproduce
[Please attach a sample project reproducing the error]
Please attach logs
Current Result
java.configuration.runtimes does not work at all and I cannot use any other JDKs except the one VSCode chooses by default.
Expected Result
I had been able to chose different JDKs per project.
Additional Informations
I have not used VSCode for my Java development for a while and found this recently.
The text was updated successfully, but these errors were encountered: