5
votes

I am setting up a new multi-module gradle project to be built in jenkins and trying to get sonarqube analysing it but I have struck several incompatibility issues which I haven't been able to resolve.

I am looking at using

  1. the sonarqube plugin because our existing projects get a warning about the deprecation of sonar-runner: The 'sonar-runner' plugin has been deprecated and is scheduled to be removed in Gradle 3.0. please use the official plugin from SonarQube (the docs).
  2. gradle 3
  3. this simple example from sonarqube https://github.com/SonarSource/sonar-examples/blob/master/projects/languages/java/gradle/java-gradle-simple/build.gradle

If I use gradle 3 I get this error: org.gradle.internal.jvm.Jvm.getRuntimeJar()Ljava/io/File;

If I use gradle 2.14 I get this error: Caused by: java.io.IOException: Incompatible version 1007 This error in the past has been caused by an incompatibility between the jacoco and sonarqube plugins see JaCoCo SonarQube incompatible version 1007.

Which versions should I use?

2
Did you find a fix for this? I am facing the same issueDimitri Kopriwa
@BigDong ,stephen, any updates about compatible versions?Spyros_av

2 Answers

2
votes

FYI the release the SonarQube Scanner for Gradle 2.1 should happen very quickly and this version includes the support of Gradle 3.X. See https://jira.sonarsource.com/browse/SONARGRADL-16 which is already fixed.

0
votes

You are not alone. I get the same issues as well. This works with gradle 2.12.

plugins {
    id 'jacoco'
    id 'java'
    id "org.sonarqube" version "2.0.1"
}