IntelliJ IDEA统计插件“内存不足" [英] IntelliJ IDEA Statistic Plugin "Out of Memory"
问题描述
我正在将 Statistic
插件用于
I'm using the Statistic
plugin for IntelliJ IDEA
. For one project of mine which has around 15.000 Java source code lines, Statistic
gets stuck at 92% progress and then IntelliJ
displays the following Out of Memory
dialog:
我尝试增加内存,但这导致 IntelliJ
拒绝启动,所以我必须再次设置默认的512MB
.
I tried increasing the memory but that causes IntelliJ
to refuse starting up so I had to set the default 512MB
again.
这是为什么引起的,如何解决它,以便我可以再次计算有关项目的统计信息?请注意,该错误不会出现在较小"的项目中.在 TaskManager
中,IntelliJ
大约位于7GB
RAM
.
Why is this caused and how can it be fixed so I can calculate statistics about my project again? Note that the error does not appear with "smaller" projects. In TaskManager
, IntelliJ
is at about 980MB
of RAM
usage but my machine has about 7GB
RAM
left in total.
推荐答案
TL,DR:排除 Statistic 插件设置中的大文件.
TL, DR: Exclude large files in the Statistic plugin settings.
出现此问题的原因是由于项目目录中有许多多GB数据文件.通过排除这些大文件,问题得以解决.
The reason I had this problem was because of many multi-GB datafiles in the project directory. By excluding these large files, the problem was solved.
在 Statistic 插件的设置中,您可以排除某些文件类型和/或排除某些(子)目录,以防止插件尝试读取它们.如果未读取文件,则文件的内容不会加载到内存中,从而防止出现内存不足"错误.
In the settings of the Statistic plugin, you can exclude some file types and/or exclude certain (sub-) directories, to prevent the plugin from trying to read them. If the files are not read, their content is not loaded into memory, preventing the Out of Memory error.
Statistic 插件的设置位于其选项卡(在左下方)的刷新"按钮下方.或者,在Pycharm->首选项->工具->统计信息中打开它们.
The setting of the Statistic plugin are found in its tab (in the bottom left), just beneath the Refresh-button. Alternatively, open them at Pycharm->Preferences->Tools->Statistic.
这篇关于IntelliJ IDEA统计插件“内存不足"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!