Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PHOENIX-5459 Enable running the test suite with JDK11 #5

Closed
wants to merge 1 commit into from

Conversation

stoty
Copy link
Contributor

@stoty stoty commented Sep 2, 2019

remove unsupported VM option
update surefire and failsafe to 2.22.2

remove unsupported VM option
update surefire and failsafe to 2.22.2
@chrajeshbabu
Copy link
Contributor

+1

@joshelser
Copy link
Member

Did you run a build, @stoty ?

$ mvn verify

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.9:jar (attach-javadocs) on project phoenix-flume: MavenReportException: Error while creating archive:
[ERROR] Exit code: 1 - javadoc: error - The code being documented uses modules but the packages defined in http://docs.oracle.com/javase/7/docs/api/ are in the unnamed module.
[ERROR]
[ERROR] Command line was: /Library/Java/JavaVirtualMachines/openjdk-11.0.2.jdk/Contents/Home/bin/javadoc @options @packages
[ERROR]
[ERROR] Refer to the generated Javadoc files in '/Users/jelser/projects/phoenix-connectors.git/phoenix-flume/target/apidocs' dir.

and

[INFO] Compiling 24 source files to /Users/jelser/projects/phoenix-connectors.git/phoenix-spark/target/classes at 1567719132252
[ERROR] error: scala.reflect.internal.MissingRequirementError: object java.lang.Object in compiler mirror not found.
[ERROR] 	at scala.reflect.internal.MissingRequirementError$.signal(MissingRequirementError.scala:17)
[ERROR] 	at scala.reflect.internal.MissingRequirementError$.notFound(MissingRequirementError.scala:18)
[ERROR] 	at scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:53)
[ERROR] 	at scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:45)
[ERROR] 	at scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:45)
[ERROR] 	at scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:66)
[ERROR] 	at scala.reflect.internal.Mirrors$RootsBase.getClassByName(Mirrors.scala:102)
[ERROR] 	at scala.reflect.internal.Mirrors$RootsBase.getRequiredClass(Mirrors.scala:105)
[ERROR] 	at scala.reflect.internal.Definitions$DefinitionsClass.ObjectClass$lzycompute(Definitions.scala:257)
[ERROR] 	at scala.reflect.internal.Definitions$DefinitionsClass.ObjectClass(Definitions.scala:257)
[ERROR] 	at scala.reflect.internal.Definitions$DefinitionsClass.init(Definitions.scala:1394)
[ERROR] 	at scala.tools.nsc.Global$Run.<init>(Global.scala:1215)
[ERROR] 	at scala.tools.nsc.Driver.doCompile(Driver.scala:31)
[ERROR] 	at scala.tools.nsc.MainClass.doCompile(Main.scala:23)
[ERROR] 	at scala.tools.nsc.Driver.process(Driver.scala:51)
[ERROR] 	at scala.tools.nsc.Driver.main(Driver.scala:64)
[ERROR] 	at scala.tools.nsc.Main.main(Main.scala)
[ERROR] 	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR] 	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[ERROR] 	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR] 	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
[ERROR] 	at scala_maven_executions.MainHelper.runMain(MainHelper.java:164)
[ERROR] 	at scala_maven_executions.MainWithArgsInFile.main(MainWithArgsInFile.java:26)

@stoty
Copy link
Contributor Author

stoty commented Sep 6, 2019

No, I haven't tried compiling with JDK 11 yet, only running the tests.
I have run mvn verify -Djvm=/path/to/JDK11/java but I always compiled with JDK8.

@stoty
Copy link
Contributor Author

stoty commented Sep 6, 2019

There is probably not much point in even trying to run the tests with JDK-11 here, as the phoenix-connector master branch depends on Phoenix4-HBase-1.5, that does HBase not support JDK11, but I wanted to get the pom incompatibility problem out of the way, and worry about branching/rebasing connectors to phoenix/master and fixing the JDK11 incompatibilities later.

@stoty
Copy link
Contributor Author

stoty commented Sep 10, 2019

It's not particularly urgent, I'm just not sure if you get notifications of my comments, @joshelser

@joshelser
Copy link
Member

Sorry, I saw it, but then didn't reply.

Ok, so this is just for running tests with JDK11, not doing the whole build with JDK8. Got it.

Iterative fixing is fine -- just want to make sure it's clear what we expect to work. Can update the README after this.

@joshelser
Copy link
Member

mvn verify -Djvm=/path/to/JDK11/java

One question, where does this -Djvm system property get defined. Is it the global to Maven itself (rather than on failsafe/surefire)?

Maybe add the expected support to BUILDING.md (or maybe create a TESTING.md), then push this +1

@stoty
Copy link
Contributor Author

stoty commented Apr 6, 2020

The -Djvm property is specific to surefire/failsafe (it could have a less confusing name).

@asfgit asfgit closed this in 3a7c03d Apr 6, 2020
@joshelser
Copy link
Member

The -Djvm property is specific to surefire/failsafe (it could have a less confusing name).

Haha, yes it could. Thanks for the answer!

@stoty stoty deleted the PHOENIX-5459 branch January 5, 2021 08:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants