Latest Java Plugin 5.13.0.18197 breaks maven analysis

  • Sonar: 6.7.7
  • Maven Plugin: 3.6.0.1398
  • Java Plugin: 5.13.0.18197

Analysing a maven project fails with

[ERROR] Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar (default-cli) on project fh-portal-service: Execution default-cli of goal org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar failed: A required class was missing while executing org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar: org/apache/xerces/jaxp/DocumentBuilderFactoryImpl
[ERROR] -----------------------------------------------------
[ERROR] realm =    plugin>org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398
[ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[ERROR] urls[0] = file:/builds/finhome/code/fh-portal-service/.m2/repository/org/sonarsource/scanner/maven/sonar-maven-plugin/3.6.0.1398/sonar-maven-plugin-3.6.0.1398.jar
[ERROR] urls[1] = file:/builds/finhome/code/fh-portal-service/.m2/repository/org/sonatype/plexus/plexus-sec-dispatcher/1.4/plexus-sec-dispatcher-1.4.jar
[ERROR] urls[2] = file:/builds/finhome/code/fh-portal-service/.m2/repository/org/sonatype/plexus/plexus-cipher/1.4/plexus-cipher-1.4.jar
[ERROR] urls[3] = file:/builds/finhome/code/fh-portal-service/.m2/repository/org/codehaus/plexus/plexus-utils/3.0.22/plexus-utils-3.0.22.jar
[ERROR] urls[4] = file:/builds/finhome/code/fh-portal-service/.m2/repository/org/sonarsource/scanner/api/sonar-scanner-api/2.12.0.1661/sonar-scanner-api-2.12.0.1661.jar
[ERROR] urls[5] = file:/builds/finhome/code/fh-portal-service/.m2/repository/commons-lang/commons-lang/2.6/commons-lang-2.6.jar
[ERROR] Number of foreign imports: 1
[ERROR] import: Entry[import  from realm ClassRealm[maven.api, parent: null]]

I was able to work around the problem by downgrading the Sonar Java Plugin to 5.12.1.17771.

Hello Christian,

I can not see anything in the release note of SonarJava 5.13 which would be related to a change in term of classloading. The logs you are showing are also not helping me to get a clear picture.

Could you share the entire log of the analysis (maybe in debug)?

Thanks,
Michael