[Environment configuration] Java multi-version installation

Background requirements

Windows computers need to use both java8 and java17

Download the installation package

I have installed java8 here

Download java17 from
https://www.oracle.com/java/technologies/downloads/#jdk17-windows
Insert image description here
and extract it to a custom directory.

Environment variable configuration

Add 3 environment variables

JAVA_HOME
JAVA17_HOME java17 jdk存放目录
JAVA8_HOME  java8 jdk安装目录,默认c:\Progam Files\Java\jdk-1.8

Insert image description here
Insert image description here
Insert image description here

Insert image description here

Insert image description here

Guess you like

Origin blog.csdn.net/tyty2211/article/details/134327870