Visual Studio Code showing “Java 11 or more recent is required to run. Please download and install a recent JDK”

后端 未结 8 2087
庸人自扰
庸人自扰 2020-12-05 17:28

Today Visual Studio Code started showing me a pop-up saying:

Java 11 or more recent is required to run. Please download and install a recent JDK.

8条回答
  •  旧巷少年郎
    2020-12-05 17:43

    I was experiencing the same issue and the following change to my setting.json file resolved the issue. Big thanks to this comment on patch notes.

    "java.home": "C:/Program Files/AdoptOpenJDK/jdk-11.0.8.10-hotspot",
    "java.configuration.runtimes": [
        {
            "name": "JavaSE-1.8",
            "path": "C:/Program Files/Java/jdk1.8.0_211",
            "default": true
        },
        {
            "name": "JavaSE-11",
            "path": "C:/Program Files/AdoptOpenJDK/jdk-11.0.8.10-hotspot",
        }
    ]
    

提交回复
热议问题