"Failed to determine Java version for profile" during "mvn site" build ...

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

"Failed to determine Java version for profile" during "mvn site" build ...

Christofer Dutz
Hi folks, ...

I'm having some trouble with a profile-activation based on java versions ...

in the PLC4X project we added a self-activating profile that changes the surefire and failsafe configuration with Java 9 and above ... everything is working nicely ... almost. Our Site-Build however is failing complaining about not being able to:

[ERROR] Failed to determine Java version for profile _allow_illegal_access_reflection_in_tests @ org.apache.plc4x:plc4x-parent:0.8.0-SNAPSHOT, /home/jenkins/jenkins-slave/workspace/PLC4X_PLC4X_develop@2/pom.xml, line 1452, column 14

Strange thing, same profile was no problem at all to enable in the normal build a few Jenkins steps for a normal “mvn deploy” before (Here we're doing a simple "mvn site") ... anyone got an idea what could be causing this?

Here a link to the Jenkins output: https://builds.apache.org/job/PLC4X/job/PLC4X/job/develop/894/console<https://slack-redir.net/link?url=https%3A%2F%2Fbuilds.apache.org%2Fjob%2FPLC4X%2Fjob%2FPLC4X%2Fjob%2Fdevelop%2F894%2Fconsole>

I did already try a few things (use maven-wrapper, output the mvn and java version , and last not least explicitly set the java-version to something) ... stupid things is that for building the site this profile is totally useless anyway.

I just even moved the profile into a sub-module and the site build is restricted to only the parent module anyway … still I’m getting the same error.