如何增加声纳 java 堆大小? [英] How to increase Sonar java heap size?

查看:32
本文介绍了如何增加声纳 java 堆大小?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用声纳分析一个相当大的项目.前几次运行正常,但现在出现错误.与时间机器和违规分析器有关:

I am analyzing quite a large project with Sonar. The first few runs went OK but now I get error. Something to do with timemachine and violation analyzer:

java.lang.OutOfMemoryError: GC overhead limit exceeded
at 
org.sonar.plugins.core.timemachine.ViolationTrackingDecorator.mapViolations(ViolationTrackingDecorator.java:131)
    at org.sonar.plugins.core.timemachine.ViolationTrackingDecorator.decorate(ViolationTrackingDecorator.java:70)

我使用 ANT 执行声纳.我可以以某种方式增加 Java 堆大小吗?

I execute Sonar using ANT. Can I increase the java heap size somehow?

推荐答案

Sonar ANT 任务作为 ANT 的一部分执行,因此您需要使用标准 ANT 环境参数设置 JVM 堆.例如:

The Sonar ANT task executes as part of ANT so you need to set the JVM heap using the standard ANT environment parameter. For example:

export ANT_OPTS=-Xmx256m

这篇关于如何增加声纳 java 堆大小?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆