Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Background initialization failed: java.lang.NoSuchMethodError: 'org.sonar.api.server.rule.RulesDefinition$NewRule org.sonar.api.server.rule.RulesDefinition$NewRule.setEffortToFixDescription(java.lang.String)' with SQ 9.1 #2252

Closed
readonlyuser1 opened this issue Sep 22, 2021 · 2 comments

Comments

@readonlyuser1
Copy link

readonlyuser1 commented Sep 22, 2021

After upgrading sonarqube from version 8.9 to version 9.1, sonarqube server does not start with plugin 2.0.5.2867.

021.09.22 05:37:39 INFO  web[][o.s.s.n.NotificationDaemon] Notification service started (delay 60 sec.)
2021.09.22 05:37:39 INFO  web[][o.s.s.a.p.ExpiredSessionsCleaner] Purge of expired session tokens has removed 0 elements
2021.09.22 05:37:39 INFO  web[][o.s.s.a.p.ExpiredSessionsCleaner] Purge of expired SAML message ids has removed 0 elements
2021.09.22 05:37:40 INFO  web[][o.s.s.s.GeneratePluginIndex] Generate scanner plugin index
2021.09.22 05:37:40 INFO  web[][o.s.s.s.RegisterMetrics] Register metrics
2021.09.22 05:37:40 INFO  web[][o.s.s.r.RegisterRules] Register rules
2021.09.22 05:37:41 INFO  web[][o.r.Reflections] Reflections took 14 ms to scan 1 urls, producing 193 keys and 193 values
2021.09.22 05:37:42 ERROR web[][o.s.s.p.Platform] Background initialization failed. Stopping SonarQube
java.lang.NoSuchMethodError: 'org.sonar.api.server.rule.RulesDefinition$NewRule org.sonar.api.server.rule.RulesDefinition$NewRule.setEffortToFixDescription(java.lang.String)'
        at org.sonar.cxx.squidbridge.annotations.AnnotationBasedRulesDefinition.setupSqaleModel(AnnotationBasedRulesDefinition.java:184)
        at org.sonar.cxx.squidbridge.annotations.AnnotationBasedRulesDefinition.addRuleClasses(AnnotationBasedRulesDefinition.java:102)
        at org.sonar.cxx.squidbridge.annotations.AnnotationBasedRulesDefinition.addRuleClasses(AnnotationBasedRulesDefinition.java:88)
        at org.sonar.plugins.cxx.CxxRuleRepository.define(CxxRuleRepository.java:34)
        at org.sonar.server.rule.RuleDefinitionsLoader.load(RuleDefinitionsLoader.java:53)
        at org.sonar.server.rule.RegisterRules.start(RegisterRules.java:119)
        at org.sonar.core.platform.StartableCloseableSafeLifecyleStrategy.start(StartableCloseableSafeLifecyleStrategy.java:40)
        at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
        at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
        at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
        at org.picocontainer.behaviors.Stored.start(Stored.java:110)
        at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1016)
        at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1009)
        at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:767)
        at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
        at org.sonar.server.platform.platformlevel.PlatformLevel.start(PlatformLevel.java:90)
        at org.sonar.server.platform.platformlevel.PlatformLevelStartup.access$001(PlatformLevelStartup.java:51)
        at org.sonar.server.platform.platformlevel.PlatformLevelStartup$1.doPrivileged(PlatformLevelStartup.java:119)
        at org.sonar.server.user.DoPrivileged.execute(DoPrivileged.java:45)
        at org.sonar.server.platform.platformlevel.PlatformLevelStartup.start(PlatformLevelStartup.java:116)
        at org.sonar.server.platform.PlatformImpl.executeStartupTasks(PlatformImpl.java:198)
        at org.sonar.server.platform.PlatformImpl$1.lambda$doRun$1(PlatformImpl.java:122)
        at org.sonar.server.platform.PlatformImpl$AutoStarterRunnable.runIfNotAborted(PlatformImpl.java:370)
        at org.sonar.server.platform.PlatformImpl$1.doRun(PlatformImpl.java:122)
        at org.sonar.server.platform.PlatformImpl$AutoStarterRunnable.run(PlatformImpl.java:354)
        at java.base/java.lang.Thread.run(Thread.java:829)
2021.09.22 05:37:42 INFO  web[][o.s.p.ProcessEntryPoint] Hard stopping process
2021.09.22 05:37:42 INFO  web[][o.s.s.n.NotificationDaemon] Notification service stopped

Desktop:

  • OS: ubuntu
  • SonarQube 9.1 (build 47736)
  • sonar-cxx-plugin-2.0.5.2867.jar
@readonlyuser1 readonlyuser1 changed the title Web server startup failed: Unable to read plugin manifest from jar : /opt/sonarqube/extensions/plugins/sonar-cxx-plugin-2.0.5.2867.jar Caused by: java.util.zip.ZipException: zip END header not found Background initialization failed: java.lang.NoSuchMethodError: 'org.sonar.api.server.rule.RulesDefinition$NewRule org.sonar.api.server.rule.RulesDefinition$NewRule.setEffortToFixDescription(java.lang.String)' Sep 22, 2021
@readonlyuser1
Copy link
Author

Idean/sonar-swift#295

@guwirth
Copy link
Collaborator

guwirth commented Sep 22, 2021

Hi @readonlyuser1,

I’m sorry but we are supporting only LTS versions:

Regards,

@guwirth guwirth changed the title Background initialization failed: java.lang.NoSuchMethodError: 'org.sonar.api.server.rule.RulesDefinition$NewRule org.sonar.api.server.rule.RulesDefinition$NewRule.setEffortToFixDescription(java.lang.String)' Background initialization failed: java.lang.NoSuchMethodError: 'org.sonar.api.server.rule.RulesDefinition$NewRule org.sonar.api.server.rule.RulesDefinition$NewRule.setEffortToFixDescription(java.lang.String)' with SQ 9.1 Sep 22, 2021
@guwirth guwirth closed this as completed Sep 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants