Copilot commented on code in PR #18499:
URL: https://github.com/apache/iotdb/pull/18499#discussion_r3819524922


##########
pom.xml:
##########
@@ -1138,7 +1126,7 @@
                             <fail>true</fail>
                             <rules>
                                 <requireJavaVersion>
-                                    <version>1.8.0</version>
+                                    <version>[17,)</version>

Review Comment:
   The minimum-JDK rule is skipped in normal Maven builds: `enforcer.skip` 
still defaults to `true` at `pom.xml:79`, and only the unused `enforce` profile 
changes it. As a result, `mvn validate` on JDK 11 does not run this rule and 
the build only fails later when compilation sees target 17. Please make the 
lightweight Java-version enforcement active by default, independently of the 
optional vulnerability checks.



##########
iotdb-client/cli/src/assembly/resources/sbin/start-cli.sh:
##########
@@ -132,20 +132,24 @@ JVM_VERSION=${jvmver%_*}
 version_arr=(${JVM_VERSION//./ })
 
 illegal_access_params=""
-#GC log path has to be defined here because it needs to access IOTDB_HOME
 if [ "${version_arr[0]}" = "1" ] ; then
-    # Java 8
     MAJOR_VERSION=${version_arr[1]}
 else
-    #JDK 11 and others
     MAJOR_VERSION=${version_arr[0]}
-    # Add argLine for Java 11 and above, due to [JEP 396: Strongly Encapsulate 
JDK Internals by Default] (https://openjdk.java.net/jeps/396)
-    illegal_access_params="$illegal_access_params 
--add-opens=java.base/java.lang=ALL-UNNAMED"
 fi
 
+if [ "$MAJOR_VERSION" -lt 17 ] ; then
+    echo "IoTDB requires Java 17 or later."
+    exit 1
+fi

Review Comment:
   The Unix CLI now rejects JDKs below 17, but the packaged Windows counterpart 
`iotdb-client/cli/src/assembly/resources/sbin/start-cli.bat` still has no 
minimum-version check and proceeds on JDK 11 until Java reports an unsupported 
class version. Add the same empty-version and `< 17` guard to the Windows 
launcher so the minimum is enforced consistently across platforms.



##########
LICENSE-binary:
##########
@@ -275,19 +284,29 @@ MIT License
 ------------
 org.slf4j:slf4j-api:2.0.9
 com.bugsnag:bugsnag:3.7.2
+io.github.classgraph:classgraph:4.8.184
 
 
 EPL 1.0
 ------------
 com.h2database:h2-mvstore:2.1.212
-ch.qos.logback:logback-classic:1.3.15
-ch.qos.logback:logback-core:1.3.15
+
+
+EPL 2.0
+------------
+ch.qos.logback:logback-classic:1.5.34
+ch.qos.logback:logback-core:1.5.34
+jakarta.annotation:jakarta.annotation-api:3.0.0
+jakarta.servlet:jakarta.servlet-api:6.0.0

Review Comment:
   The binary license inventory still omits 
`jakarta.validation:jakarta.validation-api:3.0.2` and 
`jakarta.ws.rs:jakarta.ws.rs-api:3.1.0`. Both are direct compile dependencies 
of the DataNode and the server assembly copies all dependencies into `lib` 
(`iotdb-core/datanode/src/assembly/server.xml:29-32`), so distributed archives 
contain artifacts not covered by this inventory. Add both coordinates under 
their applicable declared license sections.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to