I want to connect Gradle (Version 2.1) with SonarQube (4.5.4 LTS), but there is this Exception
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':<myProject>:sonarAnalyze'.
> java.io.IOException: Server returned HTTP response code: 400 for URL: http://localhost:9000/batch/
* Try:
Run with --debug option to get more log output.
Relating to this Post it shoud be possible, and here is maybe the Bug with the related workaround.
But how can I use it? Unpacking the zip into the Project and importing the lines from the build.gradle from the zip-file doesn't work for me :( (makes no difference).
The sonar-configuration in build.gradle:
apply plugin: "sonar"
sonar {
server {
url = "http://localhost:9000"
}
database {
url = "jdbc:mysql://localhost:3306/sonar"
driverClassName = "com.mysql.jdbc.Driver"
username = "sonar"
password = <myPassword>
}
}
apply plugin: 'sonar-runner'
sonarRunner {
sonarProperties {
property 'sonar.host.url', 'http://localhost:9000'
}
}
Thanks in advance :)
PS: Gradle and Sonarqube are working fine.