Sonar Java plugin 5.14.0.18788 crashes SonarQube

Hello,

SonarQube 7.9.1
Java 11
Sonar Java plugin 5.14.0.18788 fails but 5.13.1.18282 works

java.lang.IllegalStateException: Fail to load plugin SonarJava [java]
        at org.sonar.server.plugins.ServerExtensionInstaller.installExtensions(ServerExtensionInstaller.java:82)
        at org.sonar.server.platform.platformlevel.PlatformLevel4.start(PlatformLevel4.java:543)
        at org.sonar.server.platform.Platform.start(Platform.java:211)
        at org.sonar.server.platform.Platform.startLevel34Containers(Platform.java:185)
        at org.sonar.server.platform.Platform.access$500(Platform.java:46)
        at org.sonar.server.platform.Platform$1.lambda$doRun$0(Platform.java:119)
        at org.sonar.server.platform.Platform$AutoStarterRunnable.runIfNotAborted(Platform.java:371)
        at org.sonar.server.platform.Platform$1.doRun(Platform.java:119)
        at org.sonar.server.platform.Platform$AutoStarterRunnable.run(Platform.java:355)
        at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.NoClassDefFoundError: com/google/common/collect/RegularImmutableAsList
        at org.sonar.plugins.java.JavaPlugin.define(JavaPlugin.java:47)
        at org.sonar.server.plugins.ServerExtensionInstaller.installExtensions(ServerExtensionInstaller.java:72)
        ... 9 common frames omitted
Caused by: java.lang.ClassNotFoundException: com.google.common.collect.RegularImmutableAsList
        at org.sonar.classloader.ParentFirstStrategy.loadClass(ParentFirstStrategy.java:39)
        at org.sonar.classloader.ClassRealm.loadClass(ClassRealm.java:87)
        at org.sonar.classloader.ClassRealm.loadClass(ClassRealm.java:76)
        ... 11 common frames omitted
2019.08.09 16:02:15 DEBUG web[][o.s.s.p.Platform] Background initialization of SonarQube done
2019.08.09 16:02:15 INFO  web[][o.s.p.ProcessEntryPoint] Hard stopping process
2019.08.09 16:02:15 DEBUG web[][o.s.s.a.TomcatAccessLog] Tomcat is stopped

Hello @jblaine,

I’ve just tried on Ubuntu 18 LTS / Java 11.0.2 with SonarQube Community Edition 7.9.1 and SonarJava 5.14.0.18788 and SonarQube is starting without a problem.

I suggest 2 things:

  • download a fresh SQ CE 7.9.1 and try to upgrade SonarJava to 5.14 to see if you reproduce the problem on a vanilla installation
  • revert SonarJava to 5.13 on the instance where you have the failure and share the System Info file: this way we will see the plugins installed and in particular if you have custom plugins

Alex

2 Likes

Hi Alex, I can’t reproduce this now. I’m not sure what happened to get the SQ instance into that weird state where Sonar Java 5.14.018788 wouldn’t work, but everything is fine now. Thanks for trying to reproduce this.

1 Like