This repository has been archived by the owner on Dec 23, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 200
Examples: Maven build is broken under JDK 1.8. #1941
Comments
Marked P2 because 1) I suspect this is an issue caused by upstream dependencies and there's little we can do, and 2) Gradle build of examples still works fine. |
Confirmed Maven build succeeded under JDK 1.9 and 1.10. I think the build failure is only with JDK 1.8. |
Hi @songy23 I think this issue can be marked closed, I just tried to build the example with Here the log: bash-3.2$ java -version
java version "1.8.0_201"
Java(TM) SE Runtime Environment (build 1.8.0_201-b09)
Java HotSpot(TM) 64-Bit Server VM (build 25.201-b09, mixed mode)
bash-3.2$ mvn clean install
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Detecting the operating system and CPU architecture
[INFO] ------------------------------------------------------------------------
[INFO] os.detected.name: osx
[INFO] os.detected.arch: x86_64
[INFO] os.detected.version: 10.14
[INFO] os.detected.version.major: 10
[INFO] os.detected.version.minor: 14
[INFO] os.detected.classifier: osx-x86_64
[INFO]
[INFO] -----------------< io.opencensus:opencensus-examples >------------------
[INFO] Building opencensus-examples 0.25.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ opencensus-examples ---
[INFO] Deleting /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/target
[INFO]
[INFO] --- protobuf-maven-plugin:0.6.1:compile (default) @ opencensus-examples ---
[INFO] Compiling 1 proto file(s) to /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/target/generated-sources/protobuf/java
[INFO]
[INFO] --- protobuf-maven-plugin:0.6.1:compile-custom (default) @ opencensus-examples ---
[INFO] Compiling 1 proto file(s) to /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/target/generated-sources/protobuf/grpc-java
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ opencensus-examples ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/src/main/resources
[INFO] Copying 1 resource
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.7.0:compile (default-compile) @ opencensus-examples ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 25 source files to /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/target/classes
[INFO] /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/src/main/java/io/opencensus/examples/http/jetty/client/HelloWorldClient.java: Some input files use or override a deprecated API.
[INFO] /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/src/main/java/io/opencensus/examples/http/jetty/client/HelloWorldClient.java: Recompile with -Xlint:deprecation for details.
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ opencensus-examples ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/src/test/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.7.0:testCompile (default-testCompile) @ opencensus-examples ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ opencensus-examples ---
[INFO] No tests to run.
[INFO]
[INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ opencensus-examples ---
[INFO] Building jar: /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/target/opencensus-examples-0.25.0-SNAPSHOT.jar
[INFO]
[INFO] --- maven-install-plugin:2.4:install (default-install) @ opencensus-examples ---
[INFO] Installing /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/target/opencensus-examples-0.25.0-SNAPSHOT.jar to /Users/rahul/.m2/repository/io/opencensus/opencensus-examples/0.25.0-SNAPSHOT/opencensus-examples-0.25.0-SNAPSHOT.jar
[INFO] Installing /Users/rahul/Documents/My_Home/GCP_Work/opencensus-java/examples/pom.xml to /Users/rahul/.m2/repository/io/opencensus/opencensus-examples/0.25.0-SNAPSHOT/opencensus-examples-0.25.0-SNAPSHOT.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.866 s
[INFO] Finished at: 2019-09-23T18:53:03+05:30
[INFO] ------------------------------------------------------------------------
bash-3.2 |
Thanks @rahulKQL. Seems the fix has been rolled out to upstream dependencies. Marked as resolved now. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Please answer these questions before submitting a bug report.
What version of OpenCensus are you using?
Confirmed all versions of OpenCensus have the same problem.
What JVM are you using (
java -version
)?1.8
Maven version: Apache Maven 3.5.2
What did you do?
If possible, provide a recipe for reproducing the error.
What did you expect to see?
Maven build succeeds.
What did you see instead?
Maven build failed with logs:
Additional context
Add any other context about the problem here.
This seems an issue related to the Maven appassembler plug-in. I have tried to check out an older version of OpenCensus-Java and build the examples with Maven, but it still failed. After some investigation I suspect this is related to incompatibility introduced in JDK 9+ (similar issue: jetty/jetty.project#3244).
The text was updated successfully, but these errors were encountered: