pinchbv / android-analyzer

Android Gradle plugin for faster Sonarqube integration in Android projects. Supports Detekt and Jacoco out of the box.
http://pinch.nl
GNU General Public License v3.0
91 stars 16 forks source link

Android Project Using Java 8, SonarQube running on Java 11 #30

Open Mahesh-Venkat opened 4 years ago

Mahesh-Venkat commented 4 years ago

Hi there, I am very impressed with Android Analyzer. I am using a Mac with macOS Catlania.

Android Project looks like working Java 8. The SonarQube plugin, i used needs Java 11. JVM on my machine is set to 8.1.2 and i am getting this error, when i run ./gradlew androidAnalyzer

image

SonarScanner will require Java 11 to run starting in SonarQube 8.x SCM provider autodetection failed. Please use "sonar.scm.provider" to define SCM of your project, or disable the SCM Sensor in the project settings.

Task :app:sonarqube FAILED

AndroideRob-zz commented 4 years ago

Hi,

Thanks for your issue. I haven't tried running the plugin with Sonarqube 8.x yet. According to the official docs: https://docs.sonarqube.org/latest/requirements/requirements/, Sonarqube runners should run just fine on Java 8. The server itself, however, would require Java 11 to run.

I'm afraid you would need 2 Java versions installed on your machine - use Java 8 for Android builds and, consequently, Sonarqube scanner runs, and Java 11 for hosting the Sonarqube server.

Please let me know if this worked, good luck!