Instructions for switching the Doris master‘s java code to compile and run with JDK17
Due to the import of some new Java dependencies, the minimum jdk version requirement for Doris master's java code is JDK17. Therefore, the minimum compilation and running requirements for Doris master's Java code have been changed to JDK 17. The method and impact of switching the jdk17: 1. During the period of switching to JDK17 a. The compilation and running environment of The CI/CD pipelines have been prepared both JDK 8 and JDK 17 Java environments b. In the new code, env.sh will automatically find the JDK17 environment and set JAVA_HOME. c. This ensures that during the period of switching to JDK17, the pipeline can support PRs for both JDK 8 and JDK 17. 2. The impact of switching to JDK 17. a. The java code of Doris master branch can only be compiled and run using JDK17. b. The Master branch controls the Java code to only use the language features of JDK8 through the Maven plugin, while prohibiting the use of JDK 17 language features. This can prevent conflicts when merging PRs into other branches. c. The 1.2/2.0/2.1 branches of Doris will continue to use JDK 8 and are not affected. 3. When will JDK 17 be officially used? a. The official switch to JDK 17 will occur in the Doris 3.0 version. At that time, we can use the language features of JDK17. 4. How R&D can conveniently switch between master and 2.1 branches (using different versions of JDK)? a. Prepare both JDK 8 and JDK 17 environments, with the system default remaining as JDK 8. b. Create a custom_env.sh file in the root directory of the Doris code. Add the configuration JDK_17=/path/to/jdk17_home. c. The Doris master's code will automatically look for the JDK17 directory, while the old code will ignore this variable and continue to use JDK 8. 方铁伟 fangtie...@selectdb.com 签名由 网易灵犀办公 定制