无法提交报告 - SonarQube
Cannot submit a report - SonarQube
最近我们的 SonarQube
实例开始拒绝提交报告。下面是访问日志中的日志条目。
192.168.23.XXX - - [07/Dec/2015:16:34:53 +1100] "POST
/api/computation/submit_report?projectKey=XXX.Sonar.Test HTTP/1.1" 500 - "-" "SonarQube 5.1"
任何人都可以帮助我如何诊断这里的问题,sonar.log 没有错误。我是否缺少日志位置?
这是客户端的异常:
ERROR: Error during Sonar runner execution org.sonar.runner.impl.RunnerException: Unable to execute Sonar
at org.sonar.runner.impl.BatchLauncher.delegateExecution(BatchLauncher.java:91)
at org.sonar.runner.impl.BatchLauncher.run(BatchLauncher.java:75)
at java.security.AccessController.doPrivileged(Native Method)
at org.sonar.runner.impl.BatchLauncher.doExecute(BatchLauncher.java:69)
at org.sonar.runner.impl.BatchLauncher.execute(BatchLauncher.java:50)
at org.sonar.runner.api.EmbeddedRunner.doExecute(EmbeddedRunner.java:102)
at org.sonar.runner.api.Runner.execute(Runner.java:100)
at org.sonar.runner.Main.executeTask(Main.java:70)
at org.sonar.runner.Main.execute(Main.java:59)
at org.sonar.runner.Main.main(Main.java:53)
Caused by: java.lang.IllegalStateException: Fail to execute request [code=500, url=http://sonar.XXX.com.au:9000/api /computation/submit_report?projectKey=Quantium.Sonar.Test]: <html><body><h1>500 Internal Server Error</h1>If you are the administrator of this website, then please read this web application's log file to find out what went wrong.</body></html>
at org.sonar.batch.report.PublishReportJob.uploadMultiPartReport(PublishReportJob.java:131)
at org.sonar.batch.report.PublishReportJob.execute(PublishReportJob.java:77)
at org.sonar.batch.phases.DatabaseModePhaseExecutor.publishReportJob(DatabaseModePhaseExecutor.java:188)
at org.sonar.batch.phases.DatabaseModePhaseExecutor.execute(DatabaseModePhaseExecutor.java:134)
at org.sonar.batch.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:264)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.scan.ProjectScanContainer.scan(ProjectScanContainer.java:235)
at org.sonar.batch.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:230)
at org.sonar.batch.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:220)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.scan.ScanTask.scan(ScanTask.java:57)
at org.sonar.batch.scan.ScanTask.execute(ScanTask.java:45)
at org.sonar.batch.bootstrap.TaskContainer.doAfterStart(TaskContainer.java:135)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:158)
at org.sonar.batch.bootstrapper.Batch.executeTask(Batch.java:95)
at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:67)
at org.sonar.runner.batch.IsolatedLauncher.execute(IsolatedLauncher.java:48)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.sonar.runner.impl.BatchLauncher.delegateExecution(BatchLauncher.java:87)
如有任何帮助,我们将不胜感激
服务器确实收到了 post,但是它以 HTTP 500 响应:
2015.12.07 17:03:55 ERROR web[rails] /!\ FAILSAFE /!\ Mon Dec 07 17:03:55 +1100 2015 Status: 500 Internal Server Error No such file
or directory -
C:/Windows/system32/config/systemprofile/AppData/Local/Temp
org/jruby/RubyFile.java:842:in stat'
jar:file:/D:/sonarqube-5.1/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/shared/tmpdir.rb:33:in
tmpdir'
org/jruby/RubyArray.java:1613:in each'
jar:file:/D:/sonarqube-5.1/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/shared/tmpdir.rb:30:in
tmpdir'
jar:file:/D:/sonarqube-5.1/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/shared/tmpdir.rb:109:in
tmpdir'
jar:file:/D:/sonarqube-5.1/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/shared/tmpdir.rb:141:in
create'
org/jruby/ext/tempfile/Tempfile.java:88:in initialize'
org/jruby/RubyIO.java:852:in
new'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/utils.rb:559:in
parse_multipart'
org/jruby/RubyKernel.java:1519:in
loop'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/utils.rb:537:in
parse_multipart'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/request.rb:268:in
parse_multipart'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/request.rb:146:in
POST'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/methodoverride.rb:15:in
call'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/params_parser.rb:15:in
call'
file:/D:/sonarqube-5.1/lib/server/jruby-rack-1.1.13.2.jar!/jruby/rack/session_store.rb:70:in
context'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/session/abstract/id.rb:58:in
call'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/failsafe.rb:26:in
call'
D:/sonarqube-5.1/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:106:in
call'
file:/D:/sonarqube-5.1/lib/server/jruby-rack-1.1.13.2.jar!/rack/adapter/rails.rb:34:in
serve_rails'
file:/D:/sonarqube-5.1/lib/server/jruby-rack-1.1.13.2.jar!/rack/adapter/rails.rb:39:in
call'
file:/D:/sonarqube-5.1/lib/server/jruby-rack-1.1.13.2.jar!/rack/handler/servlet.rb:22:in
call'
似乎 JRuby 所需的 TEMPDIR 必须在 wrapper.conf 文件中设置 - 它不读取 env。变量:
set.TMPDIR={tmp 目录的路径}
我希望这对解决此问题的其他人有所帮助
在wrapper.conf中添加:
set.TMPDIR=path/to/dir
最近我们的 SonarQube
实例开始拒绝提交报告。下面是访问日志中的日志条目。
192.168.23.XXX - - [07/Dec/2015:16:34:53 +1100] "POST
/api/computation/submit_report?projectKey=XXX.Sonar.Test HTTP/1.1" 500 - "-" "SonarQube 5.1"
任何人都可以帮助我如何诊断这里的问题,sonar.log 没有错误。我是否缺少日志位置?
这是客户端的异常:
ERROR: Error during Sonar runner execution org.sonar.runner.impl.RunnerException: Unable to execute Sonar
at org.sonar.runner.impl.BatchLauncher.delegateExecution(BatchLauncher.java:91)
at org.sonar.runner.impl.BatchLauncher.run(BatchLauncher.java:75)
at java.security.AccessController.doPrivileged(Native Method)
at org.sonar.runner.impl.BatchLauncher.doExecute(BatchLauncher.java:69)
at org.sonar.runner.impl.BatchLauncher.execute(BatchLauncher.java:50)
at org.sonar.runner.api.EmbeddedRunner.doExecute(EmbeddedRunner.java:102)
at org.sonar.runner.api.Runner.execute(Runner.java:100)
at org.sonar.runner.Main.executeTask(Main.java:70)
at org.sonar.runner.Main.execute(Main.java:59)
at org.sonar.runner.Main.main(Main.java:53)
Caused by: java.lang.IllegalStateException: Fail to execute request [code=500, url=http://sonar.XXX.com.au:9000/api /computation/submit_report?projectKey=Quantium.Sonar.Test]: <html><body><h1>500 Internal Server Error</h1>If you are the administrator of this website, then please read this web application's log file to find out what went wrong.</body></html>
at org.sonar.batch.report.PublishReportJob.uploadMultiPartReport(PublishReportJob.java:131)
at org.sonar.batch.report.PublishReportJob.execute(PublishReportJob.java:77)
at org.sonar.batch.phases.DatabaseModePhaseExecutor.publishReportJob(DatabaseModePhaseExecutor.java:188)
at org.sonar.batch.phases.DatabaseModePhaseExecutor.execute(DatabaseModePhaseExecutor.java:134)
at org.sonar.batch.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:264)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.scan.ProjectScanContainer.scan(ProjectScanContainer.java:235)
at org.sonar.batch.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:230)
at org.sonar.batch.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:220)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.scan.ScanTask.scan(ScanTask.java:57)
at org.sonar.batch.scan.ScanTask.execute(ScanTask.java:45)
at org.sonar.batch.bootstrap.TaskContainer.doAfterStart(TaskContainer.java:135)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:158)
at org.sonar.batch.bootstrapper.Batch.executeTask(Batch.java:95)
at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:67)
at org.sonar.runner.batch.IsolatedLauncher.execute(IsolatedLauncher.java:48)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.sonar.runner.impl.BatchLauncher.delegateExecution(BatchLauncher.java:87)
如有任何帮助,我们将不胜感激
服务器确实收到了 post,但是它以 HTTP 500 响应:
2015.12.07 17:03:55 ERROR web[rails] /!\ FAILSAFE /!\ Mon Dec 07 17:03:55 +1100 2015 Status: 500 Internal Server Error No such file or directory - C:/Windows/system32/config/systemprofile/AppData/Local/Temp org/jruby/RubyFile.java:842:in
stat' jar:file:/D:/sonarqube-5.1/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/shared/tmpdir.rb:33:in
tmpdir' org/jruby/RubyArray.java:1613:ineach' jar:file:/D:/sonarqube-5.1/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/shared/tmpdir.rb:30:in
tmpdir' jar:file:/D:/sonarqube-5.1/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/shared/tmpdir.rb:109:intmpdir' jar:file:/D:/sonarqube-5.1/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/shared/tmpdir.rb:141:in
create' org/jruby/ext/tempfile/Tempfile.java:88:ininitialize' org/jruby/RubyIO.java:852:in
new' D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/utils.rb:559:inparse_multipart' org/jruby/RubyKernel.java:1519:in
loop' D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/utils.rb:537:inparse_multipart' D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/request.rb:268:in
parse_multipart' D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/request.rb:146:inPOST' D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/methodoverride.rb:15:in
call' D:/sonarqube-5.1/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/params_parser.rb:15:incall' file:/D:/sonarqube-5.1/lib/server/jruby-rack-1.1.13.2.jar!/jruby/rack/session_store.rb:70:in
context' D:/sonarqube-5.1/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/session/abstract/id.rb:58:incall' D:/sonarqube-5.1/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/failsafe.rb:26:in
call' D:/sonarqube-5.1/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:106:incall' file:/D:/sonarqube-5.1/lib/server/jruby-rack-1.1.13.2.jar!/rack/adapter/rails.rb:34:in
serve_rails' file:/D:/sonarqube-5.1/lib/server/jruby-rack-1.1.13.2.jar!/rack/adapter/rails.rb:39:incall' file:/D:/sonarqube-5.1/lib/server/jruby-rack-1.1.13.2.jar!/rack/handler/servlet.rb:22:in
call'
似乎 JRuby 所需的 TEMPDIR 必须在 wrapper.conf 文件中设置 - 它不读取 env。变量:
set.TMPDIR={tmp 目录的路径}
我希望这对解决此问题的其他人有所帮助
在wrapper.conf中添加:
set.TMPDIR=path/to/dir