MisterRaindrop commented on code in PR #72:
URL: https://github.com/apache/cloudberry-pxf/pull/72#discussion_r2887247030
##########
server/pxf-service/src/scripts/pxf:
##########
@@ -380,6 +380,16 @@ function do_start() {
JAVA_OPTS=($PXF_JVM_OPTS "${PXF_OPTS[@]}")
RUN_ARGS=(--spring.config.location=classpath:/application.properties,file:${PXF_BASE}/conf/pxf-application.properties)
+ # Detect Java major version and add --add-opens flags for Java 11+
+ local java_major_version
+ java_major_version=$("$javaexe" -version 2>&1 | head -1 | sed -E
's/.*version "([0-9]+).*/\1/')
Review Comment:
if java9 java10 😂
##########
server/build.gradle:
##########
@@ -266,6 +267,7 @@ configure(javaProjects) {
"-Xlint:empty", "-Xlint:finally", "-Xlint:overrides",
"-Xlint:path", "-Xlint:-processing", "-Xlint:static",
"-Xlint:try", "-Xlint:fallthrough", "-Xlint:unchecked",
"-Xlint:-options", "-Werror"
]
+ options.compilerArgs +=
JavaVersion.current().isCompatibleWith(JavaVersion.VERSION_17) ?
["-Xlint:-removal"] : []
Review Comment:
-Xlint:-removal Should we document which APIs will be replaced in the future?
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]