Sonarqube 5找不到文件异常

时间:2015-02-14 14:10:45

标签: sonarqube sonarqube-5.0

更新到sonarqube 5.0之后,我们再也无法在Windows上分析我们的多模块项目了。

问题似乎是PhasesSumUpTimeProfiler(org.sonar.batch.profiling)类使用moduleKey作为文件名的一部分来存储转储文件,这可以有特殊字符。

String fileName = module.getKey() + "-profiler.properties";

问题是模块密钥现在包含冒号(:)字符。 有没有工作。我们如何将模块密钥更改为不与冒号字符对齐。

Caused by: java.lang.IllegalStateException: Unable to store profiler output: D:\jenkins_slave\workspace\ci-build-win-fast-sonar-ssd-64\build\.sonar\profiling\ch.imagic:ims:acquisition-profiler.properties
at org.sonar.batch.profiling.PhasesSumUpTimeProfiler.dumpToFile(PhasesSumUpTimeProfiler.java:160)
at org.sonar.batch.profiling.PhasesSumUpTimeProfiler.onProjectAnalysis(PhasesSumUpTimeProfiler.java:123)
at org.sonar.batch.phases.ProjectAnalysisEvent.dispatch(ProjectAnalysisEvent.java:42)
at org.sonar.batch.phases.ProjectAnalysisEvent.dispatch(ProjectAnalysisEvent.java:25)
at org.sonar.batch.events.EventBus.doFireEvent(EventBus.java:49)
at org.sonar.batch.events.EventBus.fireEvent(EventBus.java:43)
at org.sonar.batch.phases.PhaseExecutor.execute(PhaseExecutor.java:139)
at org.sonar.batch.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:222)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:93)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:78)
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.scanRecursively(ProjectScanContainer.java:228)
at org.sonar.batch.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:223)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:93)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:78)
at org.sonar.batch.scan.ScanTask.scan(ScanTask.java:65)
at org.sonar.batch.scan.ScanTask.execute(ScanTask.java:52)
at org.sonar.batch.bootstrap.TaskContainer.doAfterStart(TaskContainer.java:128)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:93)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:78)
at org.sonar.batch.bootstrap.BootstrapContainer.executeTask(BootstrapContainer.java:171)
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(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.sonar.runner.impl.BatchLauncher$1.delegateExecution(BatchLauncher.java:87)
... 63 more

Caused by: java.io.FileNotFoundException: D:\jenkins_slave\workspace\ci-build-win-fast-sonar-ssd-64\build\.sonar\profiling\ch.imagic:ims:acquisition-profiler.properties (Die Syntax für den Dateinamen, Verzeichnisnamen oder die Datenträgerbezeichnung ist falsch)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.<init>(FileOutputStream.java:221)
at java.io.FileOutputStream.<init>(FileOutputStream.java:171)
at org.sonar.batch.profiling.PhasesSumUpTimeProfiler.dumpToFile(PhasesSumUpTimeProfiler.java:156)
... 92 more

1 个答案:

答案 0 :(得分:1)

确实,这是一个错误,我们将在SonarQube 5.1中解决这个问题:SONAR-6190

同时,您不能使用分析模式 - 不幸的是。

感谢您报告此事。