I just changed the sonar server to push test coverage report, while found sonar-scanner only respect the sonar.host.url configuration from its conf/sonar-scanner.properties for plug-in cache updates, it did not care about the one assigned from cmdline. Is that expected? I assumed the options from cmdline should be taken with higher priority.
sonar-scanner -Dsonar.projectKey=engine-javaupoc-jacoco-trial -Dsonar.host.url=http://testhosta:9000 -Dsonar.coverage.jacoco.xmlReportPaths=javaxupoc-jacoco.xml -Dsonar.java.binaries=src\java -Dsonar.source= upoc\src\java -Dsonar.language=java -Dsonar.ws.timeout=600 -Dsonar.java.libraries=lib\clxjava.jar
INFO: Scanner configuration file: D:\sonar-scanner-4.3.0.2102-windows\bin…\conf\sonar-scanner.properties
INFO: Project root configuration file: NONE
INFO: SonarScanner 4.3.0.2102
INFO: Java 11.0.3 AdoptOpenJDK (64-bit)
INFO: Windows 10 10.0 amd64
INFO: User cache: C:\Users\twu.sonar\cache
ERROR: SonarQube server [http://localhost:9000] can not be reached
INFO: ------------------------------------------------------------------------
INFO: EXECUTION FAILURE
INFO: ------------------------------------------------------------------------
INFO: Total time: 4.732s
INFO: Final Memory: 3M/17M
INFO: ------------------------------------------------------------------------
ERROR: Error during SonarScanner execution
org.sonarsource.scanner.api.internal.ScannerException: Unable to execute SonarScanner analysis
at org.sonarsource.scanner.api.internal.IsolatedLauncherFactory.lambda$createLauncher$0(IsolatedLauncherFactory.java:85)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.sonarsource.scanner.api.internal.IsolatedLauncherFactory.createLauncher(IsolatedLauncherFactory.java:74)
at org.sonarsource.scanner.api.internal.IsolatedLauncherFactory.createLauncher(IsolatedLauncherFactory.java:70)
at org.sonarsource.scanner.api.EmbeddedScanner.doStart(EmbeddedScanner.java:185)
at org.sonarsource.scanner.api.EmbeddedScanner.start(EmbeddedScanner.java:123)
at org.sonarsource.scanner.cli.Main.execute(Main.java:73)
at org.sonarsource.scanner.cli.Main.main(Main.java:61)