The development environment involved in this article:
- Operating system: Windows 10
- JDK version: JDK17
introduce
OpenJDK (Open Java Development Kit) is an open source Java development tool kit, developed and released by Oracle Corporation. It includes Java compiler (javac), Java virtual machine (JVM), Java runtime environment (JRE) and other components.
Oracle JDK (Java Development Kit) is a Java development tool kit developed and maintained by Oracle Corporation. It is based on the OpenJDK code base and adds some proprietary features and tools, such as the JavaFX graphical user interface library, Java Flight Recorder performance analysis tool, etc.
text
1. Download Open JDK17
Link: https://jdk.java.net/java-se-ri/17
Select the version to download as needed (after downloading, it is a compressed package, unzip it into a directory,Warm reminder: As a programmer, do not unzip to a directory with a Chinese path.)
2. Configure environment variables
In case someone still can’t find the location to set environment variables: This computer => Right-click => Properties => Advanced System Settings => Environment Variables.
You should be able to find it now that you have installed Open JDK.
- Set JAVA_HOME, the variable value is the Open JDK decompression directory
- Create a new CLASS_PATH variable and set the variable value
CLASS_PATH
%Java_Home%\bin;%Java_Home%\lib\dt.jar;%Java_Home%\lib\tools.jar;
- Edit the system variable path and add two values
%JAVA_HOME%\bin
%JAVA_HOME%\jre\bin
3. Check whether the installation is successful
java -version
write on the back
The full text of installing Open JDK17 on Windows 10 is complete. I hope it will be helpful to you.
Corrections welcome
2023/10/07 sm76, released in Beijing