My organization uses the org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:3.4.0.2513 to run the sonarqube task and publish the results to Sonarqube Data Center Edition Version 9.8 (build 63668).
We run the sonarqube task on our CI. The project is quite large, so it takes between 20 and 30 minutes to complete, and currently, it’s the main contributor to the CI running time.
An analysis of the Gradle task has shown that the main issue with the task is that it uses a single Gradle worker (i.e., only one thread) to perform the analysis. Essentially, the task is not scalable and cannot effectively process large projects.
No, it’s not possible to run more than one task against a project. However, it’s possible to run multiple parallel tasks against subprojects that are part of a (root) project. Another possibility is to employ the Gradle Worker API, although this requires support from the plugin developers.
It doesn’t resolve the issue, does it? Otherwise, why isn’t it offered as a solution? P.S. v4.+ requires Java 17 and isn’t compatible with our current setup. But I would consider upgrading the Java version if I were sure it would resolve the issue.