【问题标题】:SonarQube ,Response code: 500 SonarRunnerSonarQube,响应代码:500 SonarRunner
【发布时间】:2016-03-23 09:38:36
【问题描述】:

我正在运行 SonarQube 5.2,并使用 SonarRunner 使用命令行对项目进行分析
然后得到这样的错误:

10:05:01.645 WARN  - SCM provider autodetection failed. No SCM provider claims t
    o support this project. Please use sonar.scm.provider to define SCM of your proj
    ect.
    10:05:01.650 INFO  - Publish mode
    10:05:01.659 INFO  - -------------  Scan Kuma.HelperLibrary
    10:05:02.535 INFO  - Language is forced to cs
    10:05:02.642 INFO  - Load server rules
    10:05:03.116 INFO  - Load server rules (done) | time=474ms
    10:05:03.613 INFO  - Base dir: c:\Kuma.HelperLibrary
    10:05:03.622 INFO  - Working dir: c:\Kuma.HelperLibrary\.sonar
    10:05:03.638 INFO  - Source paths: src
    10:05:03.640 INFO  - Source encoding: UTF-8, default locale: zh_CN
    10:05:03.643 INFO  - Index files
    10:05:04.526 INFO  - 34 files indexed
    10:05:04.543 INFO  - Quality profile for cs: Sonar way
    10:05:04.715 INFO  - All FxCop rules are disabled, skipping its execution.
    10:05:04.742 INFO  - Sensor Lines Sensor
    10:05:04.834 INFO  - Sensor Lines Sensor (done) | time=92ms
    10:05:04.836 INFO  - Sensor QProfileSensor
    10:05:04.846 INFO  - Sensor QProfileSensor (done) | time=10ms
    10:05:04.848 INFO  - Sensor org.sonar.plugins.csharp.CSharpSensor
    10:05:14.540 INFO  - Sensor org.sonar.plugins.csharp.CSharpSensor (done) | time=
    9692ms
    10:05:14.544 INFO  - Sensor SCM Sensor
    10:05:14.545 INFO  - No SCM system was detected. You can use the 'sonar.scm.prov
    ider' property to explicitly specify it.
    10:05:14.547 INFO  - Sensor SCM Sensor (done) | time=3ms
    10:05:14.548 INFO  - Sensor Code Colorizer Sensor
    10:05:15.452 INFO  - Sensor Code Colorizer Sensor (done) | time=904ms
    10:05:15.464 INFO  - Sensor CPD Sensor
    10:05:15.468 INFO  - DefaultCpdEngine is used for cs
    10:05:19.651 INFO  - Sensor CPD Sensor (done) | time=4188ms
    10:05:21.162 INFO  - Analysis reports generated in 1486ms, dir size=651 KB
    10:05:21.560 INFO  - Analysis reports compressed in 395ms, zip size=195 KB
    INFO: ------------------------------------------------------------------------
    INFO: EXECUTION FAILURE
    INFO: ------------------------------------------------------------------------
    Total time: 29.340s
    Final Memory: 9M/107M
    INFO: ------------------------------------------------------------------------
    ERROR: Error during Sonar runner execution
    ERROR: Unable to execute Sonar
    ERROR: Caused by: Fail to execute request [code=500, url=http://localhost:9000/a
    pi/ce/submit?projectKey=MyI:Kuma.HelperLibrary&projectName=Kuma.HelperLibrary&pr
    ojectBranch=]: <html><body><h1>500 Internal Server Error</h1>If you are the admi
    nistrator of this website, then please read this web application's log file to f
    ind out what went wrong.</body></html>

如果我将 URL 复制到浏览器,我会收到以下消息:

{"errors":[{"msg":"需要HTTP方法POST"}]}

如果我使用其他 SonarQubeServer 进行分析,一切正常。 所以我不知道我的服务器出了什么问题

【问题讨论】:

  • 还要确保您的 SQL Server 数据库(如果您使用的是该数据库)配置为区分大小写和区分重音 - 不这样做可能会导致各种奇怪的错误

标签: c# sonarqube sonar-runner sonarqube5.2


【解决方案1】:

您的服务器返回了500 Internal Server Error,因此您应该去检查您的服务器日志,看看出了什么问题。

(您的浏览器中的查询将不起作用,因为它正在发出 HTTP GETsonar-runner 正在此 URL 上执行 HTTP POST

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2017-09-16
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-10-13
    相关资源
    最近更新 更多