Sonar GitHub plugin should support analysis of multiple SonarQube projects in GitHub PRs

683 views
Skip to first unread message

msz...@wikia-inc.com

unread,
Oct 22, 2017, 3:09:03 PM10/22/17
to SonarQube
See the relevant discussion at https://github.com/SonarSource/sonar-github/pull/31

Currently, when SonarQube is used in conjunction with Sonar GitHub plugin to perform analysis on a GitHub pull request that changes multiple Sonar projects, only the results of the last project analysis are shown, as Sonar GitHub plugin indiscriminately deletes its own prior review comments when reviewing a project on a PR. This significantly impairs the usability of the plugin with monorepos that contain multiple deployables, as it is the subprojects, not the containing repository itself, that correspond to SonarQube projects and thus should be analyzed separately. In our use case, SonarQube is used to analyze a monorepo that contains over 60 deployables - it is not feasible to try to analyze the monorepo as a whole, nor is it manageable to setup dedicated analyzer GitHub account for each subproject.

Does this use case warrant implementation of this feature? Are there any other requirements other than the ones noted in the linked GitHub discussion that I need to be aware of before submitting an implementation of this feature?

G. Ann Campbell

unread,
Oct 25, 2017, 9:38:47 AM10/25/17
to SonarQube
Hi,

If I understand correctly, you have one repository that contains 60 independent projects ("deployables"), each of which you analyze independently in SonarQube. Your complaint is that you cannot use PR analysis on this repository when you have a PR on this repository that spans multiple SonarQube projects.

I guess I understand why you've chosen this way to manage inter-project dependencies, but your use of this "monorepo" is atypical in our experience. It was obviously not anticipated in our PR analysis coding, and we have no future plans to support it.


Ann

P.S. Please be aware that the standard courtesies (Hi, Thanks, ...) are appreciated in this group.

msz...@wikia-inc.com

unread,
Oct 25, 2017, 12:12:40 PM10/25/17
to SonarQube
Hey Ann,

Thank you very much for the quick response, it is appreciated - if this is not a common use case among SonarQube clients then of course there is no need to include such functionality in the official GitHub plugin itself.

It might be worth it to update the PR at https://github.com/SonarSource/sonar-github/pull/36 accordingly so that users who might not have followed up on this discussion here are also notified of this update.

Cheers, Máté Szabó
Reply all
Reply to author
Forward
0 new messages