Payara Server Compilation failed: reference to Module is ambiguous

120 views
Skip to first unread message

Nikolas Christou

unread,
Aug 25, 2021, 8:59:05 AM8/25/21
to Payara Forum
Hello I am trying to build payara server from source code and I get the following compilation error:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.0:compile (default-compile) on project healthcheck-cpool: Compilation failure: Compilation failure: 
[ERROR] payara_project/Payara/nucleus/payara-modules/healthcheck-cpool/src/main/java/fish/payara/nucleus/healthcheck/cpool/ConnectionPoolHealthCheck.java:[165,22] reference to Module is ambiguous
[ERROR]   both interface com.sun.enterprise.config.serverbeans.Module in com.sun.enterprise.config.serverbeans and class java.lang.Module in java.lang match
[ERROR] payara_project/Payara/nucleus/payara-modules/healthcheck-cpool/src/main/java/fish/payara/nucleus/healthcheck/cpool/ConnectionPoolHealthCheck.java:[167,26] reference to Module is ambiguous
[ERROR]   both interface com.sun.enterprise.config.serverbeans.Module in com.sun.enterprise.config.serverbeans and class java.lang.Module in java.lang match

Maven command: mvn clean install -DskipTests -PQuickBuild -T 1C
Maven version: v3.6.3
Java version: openjdk version "11.0.12" 2021-07-20
OpenJDK Runtime Environment Temurin-11.0.12+7 (build 11.0.12+7)
OpenJDK 64-Bit Server VM Temurin-11.0.12+7 (build 11.0.12+7, mixed mode)

Did anyone else get this issue before ?

Nikolas Christou

unread,
Aug 26, 2021, 7:19:59 AM8/26/21
to Payara Forum
So I successfully executed the full and also the quick build using the latest jdk 8 LTS version.

openjdk version "1.8.0_302"
OpenJDK Runtime Environment (Temurin)(build 1.8.0_302-b08)
OpenJDK 64-Bit Server VM (Temurin)(build 25.302-b08, mixed mode)

I was under the impression that the payara compilation can be done with latest jdk 11 LTS but this might not be the case.

Ondro Mihályi

unread,
Aug 26, 2021, 9:01:46 PM8/26/21
to Nikolas Christou, Payara Forum
Yes, it's true. Java 8 is still required to build Payara Server. We plan to add support for running and compiling Payara Server on JDK 17 in near future but we're not there yet.

Ondro

št 26. 8. 2021 o 13:20 Nikolas Christou <nik....@gmail.com> napísal(a):
--
You received this message because you are subscribed to the Google Groups "Payara Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to payara-forum...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/payara-forum/524d1daf-0fee-4cdd-8141-2d74008de129n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages