
Besides, increasing to some finite max does not ultimately get rid of the issue. I could increase the max heap size using command line option to java, but that would require figuring out available RAM and writing some launching program or script. Given this situation, how should I deal with this constraint? After a quick research I found Ergonomics in the 5.0 Java Virtual Machine and others saying on Windows machine the JVM defaults max heap size as 64MB.


The user can open unlimited number of files, and the program keeps the opened objects in the memory. Recently, I am running into : Java heap space error because I am not being conservative on memory usage. I am writing a client-side Swing application (graphical font designer) on Java 5.
