Generic Issue Import - doesn't add data to the resulting 'sonar.report' file

I use:
SonarQube Version 7.6 (build 21501)
SonarQube Scanner 3.3.0.1492

I execute the following command:
sonar-scanner -Dsonar.projectKey=testkey -Dsonar.sources=. -Dsonar.externalIssuesReportPaths=SonarQubeIssueData.json -Dsonar.report.export.path=sonar-report.json -Dsonar.analysis.mode=preview

I use the last 2 items in order to get the resulting report locally for further sending to gerrit (as comments)

I took the content for the SonarQubeIssueData.json from the doc, specifying the real filePath.
However, I do not see any ā€œgenerated errorsā€ in my resulting sonar-report.json

Maybe I should install some sonar-plugin for this to work or am I doing something wrong? Can anyone give some advice?

Hi,

Welcome to the community!

First, your version is past EOL. You should upgrade to either the latest version or the current LTS at your earliest convenience. Your upgrade path is:

7.6 ā†’ 7.9.6 ā†’ 8.9.2 ā†’ 9.0.1 (last step optional)

Regarding your actual question, that report hasnā€™t been supported for quite some time, so Iā€™m not surprised that external issues never got added to it. I would have told you the two features didnā€™t overlap, but obviously Iā€™d have been wrong about that.

 
:woman_shrugging:
Ann

2 Likes

Thanks for your answer, Ann!
Iā€™d like to use a similar mechanism for reporting to gerrit.
Iā€™m interested in: are there modern tools allow to do something like that?
I mean saving a ā€˜sonar reportā€™ for sending it to gerrit? Or such things are no longer supported at all?

Hi,

Sorry, but Iā€™m really not aware of anything to facilitate Gerrit integration.

Ā 
:woman_shrugging:
Ann