I'm getting java.lang.OutOfMemoryError in one of my java application. I increased size of minimum and maximum heap size under "VM arguments" in eclipse:
-XX:+HeapDumpOnOutOfMemoryError -Xmx8g -Xms2g However, I'm still getting same error. In jconsole.exe it displays the following:
If I understood correctly, then I still have plenty of heap memory.
I also analyzed the memory dump using eclipse MAT
As you can see, it shows problem but only 9 MB. So what's exactly the problem? shouldn't I have enough free heap memory?