My Jenkins job uses the Sonarqube plugin to start an analysis. It is reported that sonar.java.libraries
is not set and the result may be inaccurate.
What value should I assign to this variable? The project is built with a maven build step. So all the dependecies are somewhere on the jenkins node under /var/lib/jenkins/.m2/repository/
.
Is sonar.java.libraries = /var/lib/jenkins/.m2/repository/**
really a correct value or did I misunderstand something?
Using all files in your maven repository should work but it might make the analysis slower as the plugin will have to look for classes in high number of jars.
You should use the SonarQube scanner for maven. It will automatically pick up the classpath from your maven configuration.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With