Open resoli opened 1 year ago
@resoli try defining this environment variable before building (the "add-opens" is for JDK17, you might not need it in JDK11):
export JAVA_TOOL_OPTIONS=' -Djdk.util.zip.disableZip64ExtraFieldValidation=true -Djdk.nio.zipfs.allowDotZipEntry=true --add-opens=java.base/java.net=ALL-UNNAMED '
The system properties in JAVA_TOOL_OPTIONS will be passed to all instances of JVM, either used directly by maven or spawned by the p2 plugin:
whose latest commit is from 2018, to support Java 10: https://github.com/wso2/maven-tools/commit/5c67180549b21d82d35d2141147184dd48094679
@gspadotto It's not only that.
This core WSO2 dependency is built with wrong ZIP headers. It needs to be fixed on WSO2 side.
org.wso2.ei:org.wso2.micro.integrator.inbound.endpoint:4.2.0
This leads to behaviouor, where if I want to develop my custom inbound endpoint, I am not able to reference and import classes from this jar, becuase the whole IDE would have to be run with JAVA_TOOL_OPTIONS
. And IDEA does not like that.
There might be more libraries like that, I haven't checked that.
Building on Ubuntu desktop 22.04, openjdk is from current package:
openjdk-11-jdk:amd64 11.0.20.1+1-0ubuntu1~22.04 amd64 OpenJDK Development Kit (JDK)
First failure: executing
mvn clean install -DskipTests -Dmaven.test.skip=true -U
Build fails at
WSO2 Micro Integrator - Mediation Initializer
:This can be avoided setting the java system property
-Djdk.util.zip.disableZip64ExtraFieldValidation=true
, that is building with:MAVEN_OPTS="-Djdk.util.zip.disableZip64ExtraFieldValidation=true" mvn clean install -DskipTests -Dmaven.test.skip=true -U
Second failure: executing
MAVEN_OPTS="-Djdk.util.zip.disableZip64ExtraFieldValidation=true" mvn clean install -DskipTests -Dmaven.test.skip=true -U
Build fails at
Running Equinox P2 Publisher Application for Repository Generation
:No workaround for this atm.
Build is ok with a previous openjdk version, (tested with
11.0.8
)