If I run my GWT application in eclipse in development mode and click around in the browser for some time, I always get an "out of memory" error in eclipse. My computer has 16 GB Ram, and there is never used more than 8GB.
I tried several config parameters. The VM-arguments in my Run configuration contain these parameters: "-Xms8192m -Xmx8192m"
Even in the eclipse.ini I tested several config parameters and now it looks like this:
--launcher.XXMaxPermSize
8192M
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
8192m
--launcher.defaultAction
openFile
--launcher.appendVmargs
-vmargs
-Dosgi.requiredJavaVersion=1.6
-Xms8192m
-Xmx8192m
But I still get the error. Is there any way to prevent this?
If the browser application is throwing the OutOfMemoryError
, then you don't need to change the Eclipse settings (eclipse.ini), that's only for Eclipse itself (more memory, usually faster workbench).
To increase an app's memory (any Java app launched from Eclipse), go to the Run/Debug configurations...
in the Run menu and set the VM arguments
on the Arguments
tab of the app's run config:
-Xms128M -Xmx1024M -XX:MaxPermSize=256M
put this in vm arguments in your run configurations: -Xmx2048M -XX:MaxPermSize=512m
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With