My project requires me to display cppcheck .xml results in SonarQube. I have installed Enterprise edition of Sonarqube with Version 8.7.1 (build 42226). I have followed the instructions as mentioned at https://github.com/SonarQubeCommunity/sonar-cppcheck , but the Sonarqube server crashes immediaetly. Is cppcheck still supported in Sonarqube latest version ?
Error in Sonarqube log:
java.lang.IllegalStateException: Fail to load plugin SonarQube :: Cppcheck Plugin [cppcheck]
at org.sonar.server.plugins.ServerExtensionInstaller.installExtensions(ServerExtensionInstaller.java:80)
at org.sonar.server.platform.platformlevel.PlatformLevel4.start(PlatformLevel4.java:574)
at org.sonar.server.platform.PlatformImpl.start(PlatformImpl.java:213)
at org.sonar.server.platform.PlatformImpl.startLevel34Containers(PlatformImpl.java:187)
at org.sonar.server.platform.PlatformImpl.access$500(PlatformImpl.java:46)
at org.sonar.server.platform.PlatformImpl$1.lambda$doRun$0(PlatformImpl.java:120)
at org.sonar.server.platform.PlatformImpl$AutoStarterRunnable.runIfNotAborted(PlatformImpl.java:370)
at org.sonar.server.platform.PlatformImpl$1.doRun(PlatformImpl.java:120)
at org.sonar.server.platform.PlatformImpl$AutoStarterRunnable.run(PlatformImpl.java:354)
at java.base/java.lang.Thread.run(Thread.java:835)
Caused by: java.lang.NoClassDefFoundError: com/google/common/collect/ImmutableList
at org.sonarqube.cppcheck.CppcheckPlugin.getExtensions(CppcheckPlugin.java:35)
at org.sonar.api.SonarPlugin.define(SonarPlugin.java:51)
at org.sonar.server.plugins.ServerExtensionInstaller.installExtensions(ServerExtensionInstaller.java:70)
... 9 common frames omitted
Caused by: java.lang.ClassNotFoundException: com.google.common.collect.ImmutableList
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)
... 12 common frames omitted
2021.04.15 13:33:48 INFO web[][o.s.p.ProcessEntryPoint] Hard stopping process
2021.04.15 13:33:49 INFO web[][o.s.s.p.d.EmbeddedDatabase] Embedded database stopped
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
We have not been involved in the SonarQube addon so I have no idea what the status of that is.
Their latest commit in that sonarcube-cppcheck repo was 5 years ago so I'd think there is likely some change in SonarQube so the addon would need some little tweak.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I don't know what's exactly included in SonarQube Enterprise but I am using the Community edition with this 3rd-party(!) plugin for C++ support: https://github.com/SonarOpenCommunity/sonar-cxx
Any problems should be reported to the developers of the according software.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
My project requires me to display cppcheck .xml results in SonarQube. I have installed Enterprise edition of Sonarqube with Version 8.7.1 (build 42226). I have followed the instructions as mentioned at https://github.com/SonarQubeCommunity/sonar-cppcheck , but the Sonarqube server crashes immediaetly. Is cppcheck still supported in Sonarqube latest version ?
Error in Sonarqube log:
java.lang.IllegalStateException: Fail to load plugin SonarQube :: Cppcheck Plugin [cppcheck]
at org.sonar.server.plugins.ServerExtensionInstaller.installExtensions(ServerExtensionInstaller.java:80)
at org.sonar.server.platform.platformlevel.PlatformLevel4.start(PlatformLevel4.java:574)
at org.sonar.server.platform.PlatformImpl.start(PlatformImpl.java:213)
at org.sonar.server.platform.PlatformImpl.startLevel34Containers(PlatformImpl.java:187)
at org.sonar.server.platform.PlatformImpl.access$500(PlatformImpl.java:46)
at org.sonar.server.platform.PlatformImpl$1.lambda$doRun$0(PlatformImpl.java:120)
at org.sonar.server.platform.PlatformImpl$AutoStarterRunnable.runIfNotAborted(PlatformImpl.java:370)
at org.sonar.server.platform.PlatformImpl$1.doRun(PlatformImpl.java:120)
at org.sonar.server.platform.PlatformImpl$AutoStarterRunnable.run(PlatformImpl.java:354)
at java.base/java.lang.Thread.run(Thread.java:835)
Caused by: java.lang.NoClassDefFoundError: com/google/common/collect/ImmutableList
at org.sonarqube.cppcheck.CppcheckPlugin.getExtensions(CppcheckPlugin.java:35)
at org.sonar.api.SonarPlugin.define(SonarPlugin.java:51)
at org.sonar.server.plugins.ServerExtensionInstaller.installExtensions(ServerExtensionInstaller.java:70)
... 9 common frames omitted
Caused by: java.lang.ClassNotFoundException: com.google.common.collect.ImmutableList
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)
... 12 common frames omitted
2021.04.15 13:33:48 INFO web[][o.s.p.ProcessEntryPoint] Hard stopping process
2021.04.15 13:33:49 INFO web[][o.s.s.p.d.EmbeddedDatabase] Embedded database stopped
We have not been involved in the SonarQube addon so I have no idea what the status of that is.
Their latest commit in that sonarcube-cppcheck repo was 5 years ago so I'd think there is likely some change in SonarQube so the addon would need some little tweak.
I don't know what's exactly included in SonarQube Enterprise but I am using the Community edition with this 3rd-party(!) plugin for C++ support: https://github.com/SonarOpenCommunity/sonar-cxx
Any problems should be reported to the developers of the according software.