gpt4 book ai didi

java - Sonarqube 6.7 计算引擎错误

转载 作者:行者123 更新时间:2023-11-30 06:24:42 25 4
gpt4 key购买 nike

有人对此有任何线索吗?

“目录尚未设置” - 不知道这意味着什么,其他项目工作正常,这个项目相当大,有 13,500 个 java 文件,另外还有 2500 个其他文件。对构建服务器的分析完成得很好,但 Web 服务器上的 CE 在这个项目中出现了问题。

较小的项目没有问题。

另外,有人知道如何在服务器上重新运行此任务,而无需再次执行整整一个小时的 Sonar 运行程序吗?

2017.11.22 09:43:03 INFO  ce[][o.s.ce.app.CeServer] Compute Engine is operational2017.11.22 10:17:07 INFO  ce[AV_kFoAKPGI1NQcqJopo][o.s.c.t.CeWorkerImpl] Execute task | project=large_java_project | type=REPORT | id=AV_kFoAKPGI1NQcqJopo | submitter=gbizeau2017.11.22 10:17:07 ERROR ce[AV_kFoAKPGI1NQcqJopo][o.s.s.c.t.s.ComputationStepExecutor] Execution of listener failedjava.lang.IllegalStateException: Directory has not been set yet        at org.sonar.server.computation.task.projectanalysis.batch.BatchReportDirectoryHolderImpl.getDirectory(BatchReportDirectoryHolderImpl.java:37)        at org.sonar.server.computation.task.projectanalysis.batch.BatchReportReaderImpl.ensureInitialized(BatchReportReaderImpl.java:53)        at org.sonar.server.computation.task.projectanalysis.batch.BatchReportReaderImpl.readContextProperties(BatchReportReaderImpl.java:222)        at org.sonar.server.computation.task.projectanalysis.api.posttask.PostProjectAnalysisTasksExecutor.createProjectAnalysis(PostProjectAnalysisTasksExecutor.java:123)        at org.sonar.server.computation.task.projectanalysis.api.posttask.PostProjectAnalysisTasksExecutor.finished(PostProjectAnalysisTasksExecutor.java:103)        at org.sonar.server.computation.task.step.ComputationStepExecutor.executeListener(ComputationStepExecutor.java:71)        at org.sonar.server.computation.task.step.ComputationStepExecutor.execute(ComputationStepExecutor.java:56)        at org.sonar.server.computation.task.projectanalysis.taskprocessor.ReportTaskProcessor.process(ReportTaskProcessor.java:73)        at org.sonar.ce.taskprocessor.CeWorkerImpl.executeTask(CeWorkerImpl.java:134)        at org.sonar.ce.taskprocessor.CeWorkerImpl.findAndProcessTask(CeWorkerImpl.java:97)        at org.sonar.ce.taskprocessor.CeWorkerImpl.withCustomizedThreadName(CeWorkerImpl.java:81)        at org.sonar.ce.taskprocessor.CeWorkerImpl.call(CeWorkerImpl.java:73)        at org.sonar.ce.taskprocessor.CeWorkerImpl.call(CeWorkerImpl.java:43)        at java.util.concurrent.FutureTask.run(FutureTask.java:266)        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)        at java.util.concurrent.FutureTask.run(FutureTask.java:266)        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)        at java.lang.Thread.run(Thread.java:748)2017.11.22 10:17:07 ERROR ce[AV_kFoAKPGI1NQcqJopo][o.s.c.t.CeWorkerImpl] Failed to execute task AV_kFoAKPGI1NQcqJopo

其他错误...

java.lang.IllegalStateException: Fail to select data of CE task AV_kFoAKPGI1NQcqJopo        at org.sonar.db.ce.CeTaskInputDao.selectData(CeTaskInputDao.java:74)        at org.sonar.server.computation.task.projectanalysis.step.ExtractReportStep.execute(ExtractReportStep.java:59)        at org.sonar.server.computation.task.step.ComputationStepExecutor.executeSteps(ComputationStepExecutor.java:64)        at org.sonar.server.computation.task.step.ComputationStepExecutor.execute(ComputationStepExecutor.java:52)        at org.sonar.server.computation.task.projectanalysis.taskprocessor.ReportTaskProcessor.process(ReportTaskProcessor.java:73)        at org.sonar.ce.taskprocessor.CeWorkerImpl.executeTask(CeWorkerImpl.java:134)        at org.sonar.ce.taskprocessor.CeWorkerImpl.findAndProcessTask(CeWorkerImpl.java:97)        at org.sonar.ce.taskprocessor.CeWorkerImpl.withCustomizedThreadName(CeWorkerImpl.java:81)        at org.sonar.ce.taskprocessor.CeWorkerImpl.call(CeWorkerImpl.java:73)        at org.sonar.ce.taskprocessor.CeWorkerImpl.call(CeWorkerImpl.java:43)        at java.util.concurrent.FutureTask.run(FutureTask.java:266)        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)        at java.util.concurrent.FutureTask.run(FutureTask.java:266)        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)        at java.lang.Thread.run(Thread.java:748)Caused by: org.postgresql.util.PSQLException: ERROR: invalid memory alloc request size 1315662807        at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2476)        at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2189)        at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:300)        at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:428)        at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:354)        at org.postgresql.jdbc.PgPreparedStatement.executeWithFlags(PgPreparedStatement.java:169)        at org.postgresql.jdbc.PgPreparedStatement.executeQuery(PgPreparedStatement.java:117)        at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)        at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)        at org.sonar.db.ce.CeTaskInputDao.selectData(CeTaskInputDao.java:67)        ... 17 common frames omitted

更新:所以到目前为止我还无法“调整”postgresql 以处理这些更大的大小。我们的项目未压缩为 3GB。我发现 2GB 不需要在我们的构建文件夹(rpm 等)中的静态代码并将其删除,SonarQube 现在可以运行了。虽然这并不能解决问题,但我希望其他人可以使用此信息来解决同样的问题。

最佳答案

恐怕您报告的堆栈跟踪隐藏了另一个错误,这才是真正的问题。

构建参数以调用 Compute Engine 中的公共(public) PostTask API 时,会发生报告的错误。您可以将这段代码视为在finally block 中执行。我已经开了一张票来解决这个隐藏问题SONAR-10115 .

但是,该错误确实间接确认了提取报告时存在问题。我们“只是”不知道到底是哪一个。我们可以假设它与报告的大小有关。

从数据库中获取报告的 ZIP 并将其流式提取到磁盘。

以下是一些可能出现问题的想法:

  • 您的数据库无法将整个文件(超时或其他原因)传输到服务器
  • 由于可用空间不足,提取到磁盘失败(取决于数据库供应商和配置、网络等)
  • 或达到文件和/或目录数量限制(取决于操作系统)
  • 流式传输未按预期运行并引发 OOM

关于java - Sonarqube 6.7 计算引擎错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47439872/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com