All Questions

72
votes
8answers
57221 views

How to configure multi-module Maven + Sonar + JaCoCo to give merged coverage report?

I've searched up and down the internet for this one. There's lots of half-answers out there, to do with Maven properties such as ${sonar.jacoco.reportPath}, or org.jacoco:jacoco-maven-plugin:prepare-a...
64
votes
4answers
32400 views

New Integer vs valueOf

I was using Sonar to make my code cleaner, and it pointed out that I'm using new Integer(1) instead of Integer.valueOf(1). Because it seems that valueOf does not instantiate a new object so is more me...
59
votes
7answers
46351 views

Sonar Violation: Security - Array is stored directly

There is a Sonar Violation: Sonar Violation: Security - Array is stored directly public void setMyArray(String[] myArray) { this.myArray = myArray; } Solution: public void setMyArray(String[...
9
votes
3answers
23085 views

SONAR - Measure Code Coverage using Cobertura

I am using sonar to measure code quality. One thing that I do not know is the steps to measure code coverage using Cobertura. I followed the steps from http://cobertura.sourceforge.net/anttaskrefere...
3
votes
1answers
8151 views

integrating JaCoCo in sonar using Ant

I am stuck integrating JaCoCo with sonar using Ant. Very new to this task, and integrating for the first time. I have gone through many links like https://github.com/SonarSource/sonar-examples/blob/...
15
votes
2answers
12804 views

jenkins + sonar + github integration

Problem: I am setting up jenkins + sonar + github integration for automatic pullrequest static code check through sonar. My Configuration: Installed Sonar with github Installed jenkins In jenkins p...
3
votes
1answers
573 views

What is the correct way to configure an Android project with submodules for use with the sonarqube gradle plugin?

What is the correct way to configure an Android project with submodules for use with the sonarqube gradle plugin? Google has not been my friend, but I may have missed something basic. (I search for ...
80
votes
4answers
71065 views

Turning Sonar off for certain code

Is it possible to turn off sonar (www.sonarsource.org) measurements for specific blocks of code, which one doesn't want to be measured? An example is the "Preserve Stack Trace" warning which Findbugs...
13
votes
4answers
50471 views

How to configure Maven to run a SonarQube project analysis with two different quality profiles?

We run SonarQube analyses for our Java projects via Maven. Maven somehow does this automagically; all we did was add the sonar-maven-plugin to our pom.xml: <pluginManagement> <plugins&...
32
votes
1answers
36045 views

Do I need sonar and sonar runner for Jenkins?

I want to set up Sonar with Jenkins. But I'm not sure if the Sonar site describes two different ways to do this or if there are two necessary steps: As far as I understood it, it's two different ways...

Previous Next