mc1arke / sonarqube-community-branch-plugin

A plugin that allows branch analysis and pull request decoration in the Community version of Sonarqube

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

is 10.6 supported?

matteo-rama opened this issue · comments

hi,

someone try the plugin with sonar 10.6? it's supported and/or working?

thanks!

Hi,
Apparently it is not supported.

I did get this error after upgrading sonarqube to 10.6.x :

Error creating bean with name 'org.sonarsource.scanner.api.internal.IsolatedClassloader@54c622a7-org.sonar.scanner.scan.ModuleIndexer': Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.sonarsource.scanner.api.internal.IsolatedClassloader@54c622a7-org.sonar.scanner.scan.filesystem.InputComponentStore': Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'BranchConfiguration' defined in org.sonar.scanner.scan.branch.BranchConfigurationProvider: Unsatisfied dependency expressed through method 'provide' parameter 2; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'ProjectBranches' defined in org.sonar.scanner.scan.branch.ProjectBranchesProvider: Unsatisfied dependency expressed through method 'provide' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'java.net.FactoryURLClassLoader@26101efc-com.github.mc1arke.sonarqube.plugin.scanner.CommunityProjectBranchesLoader': Resolution of declared constructors on bean Class [com.github.mc1arke.sonarqube.plugin.scanner.CommunityProjectBranchesLoader] from ClassLoader [java.net.FactoryURLClassLoader@26101efc] failed; nested exception is java.lang.NoClassDefFoundError: org/sonar/scanner/bootstrap/ScannerWsClient: org.sonar.scanner.bootstrap.ScannerWsClient

The class org.sonar.scanner.bootstrap.ScannerWsClient had been move to org.sonar.scanner.http.ScannerWsClient.
I fixed the import and compiled the plugin locally, and this fixed the problem, here are the changes i made :

image

image

Same issue on my project.

We have the same issue after upgrading SonarQube Community Edition v10.6 (92116):

[ERROR] Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin:4.0.0.4121:sonar (default-cli) on project apm-services: Error creating bean with name 'org.sonarsource.scanner.api.internal.IsolatedClassloader@3e59c322-org.sonar.scanner.scan.ModuleIndexer': Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.sonarsource.scanner.api.internal.IsolatedClassloader@3e59c322-org.sonar.scanner.scan.filesystem.InputComponentStore': Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'BranchConfiguration' defined in org.sonar.scanner.scan.branch.BranchConfigurationProvider: Unsatisfied dependency expressed through method 'provide' parameter 2; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'ProjectBranches' defined in org.sonar.scanner.scan.branch.ProjectBranchesProvider: Unsatisfied dependency expressed through method 'provide' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'java.net.FactoryURLClassLoader@2e7ab100-com.github.mc1arke.sonarqube.plugin.scanner.CommunityProjectBranchesLoader': Resolution of declared constructors on bean Class [com.github.mc1arke.sonarqube.plugin.scanner.CommunityProjectBranchesLoader] from ClassLoader [java.net.FactoryURLClassLoader@2e7ab100] failed; nested exception is java.lang.NoClassDefFoundError: org/sonar/scanner/bootstrap/ScannerWsClient: org.sonar.scanner.bootstrap.ScannerWsClient -> [Help 1]

@mohamedazaddou It work's !!

Thanks you so much!

Please, add the patch to the main branch @mohamedazaddou

Oehh would be very nice to have this patch on the main branch 😄

Hi,
Someone already opened a pull request to fix this :
#927

Release in 1.21.0