Closed obrienben closed 4 years ago
I can build and run it with jdk 11. There's no openjdk 9 package for my OS. Maybe we should consider support for 9 and up experimental until we've had it running on those newer jdks for a while?
For OpenJDK 11, I can build and run modules of webcurator-legacy-lib-dependencies, webcurator-core, webcurator-submit-to-rosetta, webcurator-store, ebcurator-harvest-agent-h3 and webcurator-webapp. Succeed to harvest with H3. There was NO webservice called in this process. I think the APT twn Rosetta must be tested in UAT environment to verify webservice APIs.
For OpenJDK 9, I failed to build with OpenJDK 9 and Oracle JDK 9. The JDK downloading URL: https://jdk.java.net/java-se-ri/9
1) Maven Environment:
Apache Maven 3.6.3
Maven home: /usr/share/maven
Java version: 9, vendor: Oracle Corporation, runtime: /home/leefr/Application/jdk-9
Default locale: en_NZ, platform encoding: UTF-8
OS name: "linux", version: "5.4.0-42-generic", arch: "amd64", family: "unix"
2) Gradle Environment:
------------------------------------------------------------
Gradle 5.6
------------------------------------------------------------
Build time: 2019-08-14 21:05:25 UTC
Revision: f0b9d60906c7b8c42cd6c61a39ae7b74767bb012
Kotlin: 1.3.41
Groovy: 2.5.4
Ant: Apache Ant(TM) version 1.9.14 compiled on March 12 2019
JVM: 9 (Oracle Corporation 9+181)
OS: Linux 5.4.0-42-generic amd64
3) Error Message:
Could not resolve com.google.code.guice:guice:1.0.
Required by:
project :
> Could not resolve com.google.code.guice:guice:1.0.
> Could not get resource 'https://repo.maven.apache.org/maven2/com/google/code/guice/guice/1.0/guice-1.0.pom'.
> Could not GET 'https://repo.maven.apache.org/maven2/com/google/code/guice/guice/1.0/guice-1.0.pom'.
> java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty
> Could not resolve com.google.code.guice:guice:1.0.
> Could not get resource 'https://repo1.maven.org/maven2/com/google/code/guice/guice/1.0/guice-1.0.pom'.
> Could not GET 'https://repo1.maven.org/maven2/com/google/code/guice/guice/1.0/guice-1.0.pom'.
> java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty
4) Reproduce Proceduture: At first remove all local cached libs (~/.m2/repository/*) or build in a brand new development environment. Then run: "webcurator-legacy-lib-dependencies/install_maven_dependencies.sh" or "./gradlew clean install" with "webcurator-core or webcurator-submit-to-rosetta". The error will happen.
@leefrank9527 thanks for testing. That issue with Java 9 seems to be independent from WCT, and more related to your Java and environment, based on similar reports of that error:
Do any of the solutions mentioned in these posts fix the issue?
@obrienben
You are right. It's related to my Java Environment. After setting some environment variables, it does work.
export JAVA_OPTS="-Djavax.net.ssl.trustStore=/etc/ssl/certs/java/cacerts"
export MAVEN_OPTS=${JAVA_OPTS}
export GRADLE_OPTS=${JAVA_OPTS}
I think it's because I'm using a portable version of JDK9, the certificates for SSL aren't installed. But it's hard to find an installing package of jdk9 for ubuntu OS.
After addressed the environment issue. I can build and run WCT with JDK9. I finished an E2E harvest process, webapp/h3/store comoponents were included.
Rebased using master, and then merged into master.
Tested WCT compatibility with OpenJDK 9.0.4 and OpenJDK 11.0.8 as I was looking at the documentation updates.
Only minor changes needed to work with Java 9 and 11, needed to explicitly include jaxb and jax-ws dependencies for harvest-agent-h3 and submit-to-rosetta modules.
To test I did the following:
NOTE: