我们正在尝试在本地设置sonarqube服务器,我们已经安装了sonarqube并设置maven设置如下

<pluginGroups>
    <pluginGroup>org.sonarsource.scanner.maven</pluginGroup>
</pluginGroups>
<profiles>
    <profile>
        <id>sonar</id>
        <activation>
            <activeByDefault>true</activeByDefault>
        </activation>
        <properties>
            <!-- Optional URL to server. Default value is http://localhost:9000 -->
            <sonar.host.url>
                http://loalhost:9000
            </sonar.host.url>
        </properties>
    </profile>
</profiles>

和扫描仪依赖关系添加到pom

<dependency>
        <groupId>org.sonarsource.scanner.api</groupId>
        <artifactId>sonar-scanner-api</artifactId>
        <version>2.10.0.1189</version>
   </dependency>

在执行mvn命令mvn clean install声纳:声纳..我们得到以下错误

Caused by: java.lang.IllegalStateException: Fail to get bootstrap index from server


Caused by: java.lang.IllegalStateException: Fail to get bootstrap index from server
        at org.sonarsource.scanner.api.internal.BootstrapIndexDownloader.getIndex(BootstrapIndexDownloader.java:42)
        at org.sonarsource.scanner.api.internal.JarDownloader.getScannerEngineFiles(JarDownloader.java:58)
        at org.sonarsource.scanner.api.internal.JarDownloader.download(JarDownloader.java:53)
        at org.sonarsource.scanner.api.internal.IsolatedLauncherFactory.lambda$createLauncher$0(IsolatedLauncherFactory.java:76)
        ... 29 more
Caused by: java.lang.IllegalStateException: Status returned by url [http://loalhost:9000/batch/index] is not valid: [404]
        at org.sonarsource.scanner.api.internal.ServerConnection.callUrl(ServerConnection.java:115)
        at org.sonarsource.scanner.api.internal.ServerConnection.downloadString(ServerConnection.java:98)
        at org.sonarsource.scanner.api.internal.BootstrapIndexDownloader.getIndex(BootstrapIndexDownloader.java:39)
        ... 32 more

最后

Fail to get bootstrap index from server: Read timed out