Java 如何使用VisualVM 1.3.6查找内存泄漏?

Java 如何使用VisualVM 1.3.6查找内存泄漏?,java,testing,memory-leaks,heap-memory,visualvm,Java,Testing,Memory Leaks,Heap Memory,Visualvm,我遵循这一点来查找内存泄漏。我在第6页上完成了以下所有步骤,结果如下。问题是,我不确定这个结果是否好,是否有内存泄漏,如何解决它 The way of measuring is: •(Switch off the automatic refreshing.) •In Visual VM start the garbage collector, by pressing the corresponding icon. •In Visual VM reset the results by pressi

我遵循这一点来查找内存泄漏。我在第6页上完成了以下所有步骤,结果如下。问题是,我不确定这个结果是否好,是否有内存泄漏,如何解决它

The way of measuring is:
•(Switch off the automatic refreshing.)
•In Visual VM start the garbage collector, by pressing the corresponding icon.
•In Visual VM reset the results by pressing the “Reset collected results” icon. Now all
delta counters are reset.
•Perform your application procedure one or several times.
•In Visual VM press start the garbage collector again
在下一页中,教程要求运行堆转储第7页,我这样做了,char[]的结果如下

更好

首先,您需要转储JVM堆:jmap-dump:format=b,file=

然后使用MAT打开转储文件

分析后,您可以看到如下图表:

在图表下方,您可以看到memroy泄漏报告