我们正在尝试将sonarqube从4.5.7升级到sonarqube 5.6 LTS版本。在升级过程中,我看到错误
2016.07.15 17:19:11 INFO web[o.s.s.p.UpdateCenterClient] Update center: http://update.sonarsource.org/update-center.properties (no proxy)
2016.07.15 17:19:11 ERROR web[o.a.c.c.C.[.[.[/sonar]] Exception sending context initialized event to listener instance of class org.sonar.server.platform.PlatformServletContextListener
java.lang.IllegalStateException: Unable to load component class org.sonar.server.qualityprofile.QProfileService
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:69) ~[sonar-core-5.6.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:632) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.BasicComponentParameter$1.resolveInstance(BasicComponentParameter.java:118) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.ComponentParameter$1.resolveInstance(ComponentParameter.java:136) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.SingleMemberInjector.getParameter(SingleMemberInjector.java:78) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$CtorAndAdapters.getParameterArguments(ConstructorInjector.java:309) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$1.run(ConstructorInjector.java:335) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjector$ThreadLocalCyclicDependencyGuard.observe(AbstractInjector.java:270) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector.getComponentInstance(ConstructorInjector.java:364) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.getComponentInstance(AbstractInjectionFactory.java:56) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.AbstractBehavior.getComponentInstance(AbstractBehavior.java:64) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.Stored.getComponentInstance(Stored.java:91) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.instantiateComponentAsIsStartable(DefaultPicoContainer.java:1034) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.addAdapterIfStartable(DefaultPicoContainer.java:1026) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1003) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:767) ~[picocontainer-2.15.jar:na]
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:141) ~[sonar-core-5.6.jar:na]
at org.sonar.server.platform.platformlevel.PlatformLevel.start(PlatformLevel.java:84) ~[sonar-server-5.6.jar:na]
at org.sonar.server.platform.platformlevel.PlatformLevel4.start(PlatformLevel4.java:693) ~[sonar-server-5.6.jar:na]
at org.sonar.server.platform.Platform.start(Platform.java:216) ~[sonar-server-5.6.jar:na]
at org.sonar.server.platform.Platform.startLevel34Containers(Platform.java:190) ~[sonar-server-5.6.jar:na]
at org.sonar.server.platform.Platform.doStart(Platform.java:113) ~[sonar-server-5.6.jar:na]
at org.sonar.server.platform.Platform.doStart(Platform.java:99) ~[sonar-server-5.6.jar:na]
at org.sonar.server.platform.PlatformServletContextListener.contextInitialized(PlatformServletContextListener.java:44) ~[sonar-server-5.6.jar:na]
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4812) [tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5255) [tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408) [tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398) [tomcat-embed-core-8.0.30.jar:8.0.30]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_92]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_92]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_92]
at java.lang.Thread.run(Thread.java:745) [na:1.8.0_92]
Caused by: java.lang.IllegalStateException: Unable to load component class org.sonar.server.qualityprofile.QProfileBackuper
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:69) ~[sonar-core-5.6.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:632) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.BasicComponentParameter$1.resolveInstance(BasicComponentParameter.java:118) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.ComponentParameter$1.resolveInstance(ComponentParameter.java:136) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.SingleMemberInjector.getParameter(SingleMemberInjector.java:78) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$CtorAndAdapters.getParameterArguments(ConstructorInjector.java:309) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$1.run(ConstructorInjector.java:335) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjector$ThreadLocalCyclicDependencyGuard.observe(AbstractInjector.java:270) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector.getComponentInstance(ConstructorInjector.java:364) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.getComponentInstance(AbstractInjectionFactory.java:56) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.AbstractBehavior.getComponentInstance(AbstractBehavior.java:64) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.Stored.getComponentInstance(Stored.java:91) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.getInstance(DefaultPicoContainer.java:699) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:647) ~[picocontainer-2.15.jar:na]
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:67) ~[sonar-core-5.6.jar:na]
... 32 common frames omitted
Caused by: java.lang.IllegalStateException: Unable to load component class org.sonar.server.qualityprofile.QProfileReset
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:69) ~[sonar-core-5.6.jar:na]
Caused by: java.lang.IllegalStateException: Unable to load component class org.sonar.server.qualityprofile.QProfileReset
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:69) ~[sonar-core-5.6.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:632) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.BasicComponentParameter$1.resolveInstance(BasicComponentParameter.java:118) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.ComponentParameter$1.resolveInstance(ComponentParameter.java:136) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.SingleMemberInjector.getParameter(SingleMemberInjector.java:78) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$CtorAndAdapters.getParameterArguments(ConstructorInjector.java:309) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$1.run(ConstructorInjector.java:335) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjector$ThreadLocalCyclicDependencyGuard.observe(AbstractInjector.java:270) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector.getComponentInstance(ConstructorInjector.java:364) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.getComponentInstance(AbstractInjectionFactory.java:56) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.AbstractBehavior.getComponentInstance(AbstractBehavior.java:64) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.Stored.getComponentInstance(Stored.java:91) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.getInstance(DefaultPicoContainer.java:699) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:647) ~[picocontainer-2.15.jar:na]
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:67) ~[sonar-core-5.6.jar:na]
... 46 common frames omitted
Caused by: java.lang.IllegalStateException: Unable to load component class com.contemplateltd.tools.sonar.profile.CceProfile
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:69) ~[sonar-core-5.6.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:621) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.CollectionComponentParameter.getArrayInstance(CollectionComponentParameter.java:334) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.CollectionComponentParameter.access$100(CollectionComponentParameter.java:49) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.CollectionComponentParameter$1.resolveInstance(CollectionComponentParameter.java:139) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.ComponentParameter$1.resolveInstance(ComponentParameter.java:141) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.SingleMemberInjector.getParameter(SingleMemberInjector.java:78) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$CtorAndAdapters.getParameterArguments(ConstructorInjector.java:309) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$1.run(ConstructorInjector.java:335) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjector$ThreadLocalCyclicDependencyGuard.observe(AbstractInjector.java:270) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector.getComponentInstance(ConstructorInjector.java:364) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.getComponentInstance(AbstractInjectionFactory.java:56) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.AbstractBehavior.getComponentInstance(AbstractBehavior.java:64) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.Stored.getComponentInstance(Stored.java:91) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.getInstance(DefaultPicoContainer.java:699) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:647) ~[picocontainer-2.15.jar:na]
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:67) ~[sonar-core-5.6.jar:na]
... 60 common frames omitted
Caused by: java.lang.IllegalStateException: Unable to load component class com.contemplateltd.tools.sonar.analysis.AnalyserContext
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:69) ~[sonar-core-5.6.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:632) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.BasicComponentParameter$1.resolveInstance(BasicComponentParameter.java:118) ~[picocontainer-2.15.jar:na]
at org.picocontainer.parameters.ComponentParameter$1.resolveInstance(ComponentParameter.java:136) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.SingleMemberInjector.getParameter(SingleMemberInjector.java:78) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$CtorAndAdapters.getParameterArguments(ConstructorInjector.java:309) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$1.run(ConstructorInjector.java:335) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjector$ThreadLocalCyclicDependencyGuard.observe(AbstractInjector.java:270) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector.getComponentInstance(ConstructorInjector.java:364) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.getComponentInstance(AbstractInjectionFactory.java:56) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.AbstractBehavior.getComponentInstance(AbstractBehavior.java:64) ~[picocontainer-2.15.jar:na]
at org.picocontainer.behaviors.Stored.getComponentInstance(Stored.java:91) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.getInstance(DefaultPicoContainer.java:699) ~[picocontainer-2.15.jar:na]
at org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:647) ~[picocontainer-2.15.jar:na]
at org.sonar.core.platform.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:67) ~[sonar-core-5.6.jar:na]
... 76 common frames omitted
Caused by: java.lang.NoClassDefFoundError: org/sonar/api/platform/PluginRepository
at java.lang.Class.getDeclaredConstructors0(Native Method) ~[na:1.8.0_92]
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671) ~[na:1.8.0_92]
at java.lang.Class.getDeclaredConstructors(Class.java:2020) ~[na:1.8.0_92]
at org.picocontainer.injectors.ConstructorInjector$3.run(ConstructorInjector.java:403) ~[picocontainer-2.15.jar:na]
at org.picocontainer.injectors.ConstructorInjector$3.run(ConstructorInjector.java:401) ~[picocontainer-2.15.jar:na]
任何帮助将不胜感激。
答案 0 :(得分:1)
问题来自contemplateltd插件(请参阅stacktraces中的类com.contemplateltd.tools.sonar.profile.CceProfile和com.contemplateltd.tools.sonar.analysis.AnalyserContext)。我不知道这个插件在SonarQube 5.6 LTS上的状态。你应该联系它的维护者。
答案 1 :(得分:0)
昨天我遇到了完全相同的错误,也尝试在this procedure之后从4.5.7升级到5.6。
在我的情况下,这是由于conf/sonar.properties
中的过度复制和粘贴,我复制了我的LDAP配置,而LDAP模块尚未安装。
我评论了它,应用程序能够启动。 然后我从SonarQube GUI安装了LDAP模块,重新启用了我的LDAP配置,并重新启动了应用程序。 它奏效了。
这可能不是您问题的根源,但我建议您检查一下您是否尝试启动任何未安装的模块。