Memory errors

GWT Designer allows you to quickly create the modules, composites, panels, remote services and other elements that comprise Google Web Tookit applications.

Moderators: Konstantin.Scheglov, gnebling, Alexander.Mitin, jwren, Eric Clayberg

Memory errors

Postby loachman » Sun Jun 29, 2008 12:08 pm

I have all of the sudden out of the blue started getting memory errors on every project old and new.

[ERROR] Out of memory; to increase the amount of memory, use the -Xmx flag at startup (java -Xmx128M ...)

Anyway I can fix this in the GWT Designer? And what would all the sudden start causing errors like that I wonder?

Thanks
Loachman-
loachman
 
Posts: 22
Joined: Thu May 15, 2008 10:02 am

Re: Memory errors

Postby Eric Clayberg » Sun Jun 29, 2008 12:33 pm

loachman wrote:I have all of the sudden out of the blue started getting memory errors on every project old and new.
[ERROR] Out of memory; to increase the amount of memory, use the -Xmx flag at startup (java -Xmx128M ...)
Anyway I can fix this in the GWT Designer? And what would all the sudden start causing errors like that I wonder?

Why are you assuming it is a GWT Designer issue?

What are you doing when you see these errors?

What exact version/build of Eclipse are you using?

How much memory do you have assigned to run Eclipse?

If you turn on the Heap Status indicator in Eclipse, what does it show?
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA

Re: Memory errors

Postby loachman » Fri Jul 18, 2008 10:10 am

Hi,

I have gotten this resolved on an "older box" of mine, strange as it may be. This box has less ram the CPU is older, etc..
But it is working for now so I am happy until I can pinpoint the problem.
loachman
 
Posts: 22
Joined: Thu May 15, 2008 10:02 am

Re: Memory errors

Postby Eric Clayberg » Fri Jul 18, 2008 10:14 am

The amount of ram on the box rarely is an issue.

The amount of memory assigned to Eclipse is the issue.
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA

Re: Memory errors

Postby loachman » Fri Jul 18, 2008 3:36 pm

Maybe I spoke too soon.
I am using the beta release.

I have a project I created via the command line. It works in eclipse just fine until I install GWT Designer then upon trying to run it I get the following errors.

[ERROR] Failure to load module 'com.sinewavemultimedia.metronome.SliderApp'
java.lang.OutOfMemoryError: Java heap space
at com.google.gwt.dev.javac.TypeOracleMediator.parseMetaDataTags(TypeOracleMediator.java:151)
at com.google.gwt.dev.javac.TypeOracleMediator.resolveMethod(TypeOracleMediator.java:1031)
at com.google.gwt.dev.javac.TypeOracleMediator.resolveMethods(TypeOracleMediator.java:1044)
at com.google.gwt.dev.javac.TypeOracleMediator.resolveTypeDeclaration(TypeOracleMediator.java:1434)
at com.google.gwt.dev.javac.TypeOracleMediator.refresh(TypeOracleMediator.java:382)
at com.google.gwt.dev.javac.CompilationState.compile(CompilationState.java:102)
at com.google.gwt.dev.cfg.ModuleDef.updateTypeOracle(ModuleDef.java:477)
at com.google.gwt.dev.cfg.ModuleDef.getTypeOracle(ModuleDef.java:324)
at com.google.gwt.dev.GWTShell$BrowserWidgetHostImpl.createModuleSpaceHost(GWTShell.java:253)
at com.google.gwt.dev.shell.ie.BrowserWidgetIE6$External.gwtOnLoad(BrowserWidgetIE6.java:67)

Also trying to run the new GWT_EXT for the 5.0.1 beta Release gives similiar errors.

I put the following into the eclipse.ini my computer has 512MB of ram (well this particular box anyways)
--launcher.XXMaxPermSize
512m
-vmargs
-Xms40m
-Xmx512m
loachman
 
Posts: 22
Joined: Thu May 15, 2008 10:02 am

Re: Memory errors

Postby Eric Clayberg » Fri Jul 18, 2008 5:17 pm

What exact version of Eclipse?
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA

Re: Memory errors

Postby loachman » Fri Jul 18, 2008 8:02 pm

Using gandymede

Version: 3.4.0
Build id: I20080617-2000


Thanks
loachman
 
Posts: 22
Joined: Thu May 15, 2008 10:02 am

Re: Memory errors

Postby Konstantin.Scheglov » Sat Jul 19, 2008 3:06 am

loachman wrote:Maybe I spoke too soon.
I am using the beta release.

[cut]

I put the following into the eclipse.ini my computer has 512MB of ram (well this particular box anyways)
--launcher.XXMaxPermSize
512m
-vmargs
-Xms40m
-Xmx512m


Can you check that your Eclipse/JVM is really configured for enough memory?
Turn ON "Show heap status" in Window | Preferences | General and check max memory limit, also look how it is changed during parsing.

I use following JVM args "-XX:MaxPermSize=128m -Xms256m -Xmx256m" and this is more than enough to open simple GWT module (but with EXT GWT library attached, so it is also compiled).
Konstantin.Scheglov
Moderator
 
Posts: 186
Joined: Tue Oct 18, 2005 8:11 pm
Location: Russian Federation, Lipetsk

Re: Memory errors

Postby loachman » Sat Jul 19, 2008 7:48 am

Hi,

Using the settings you suggested. The heap status showed 40 of 256 when trying to parse and run the application.

I am using java 1.5.0_16 as my jdk, wonder if I should try a different one, or try eclipse 3.3.x again maybe.

Thanks
loachman
 
Posts: 22
Joined: Thu May 15, 2008 10:02 am

Re: Memory errors

Postby Konstantin.Scheglov » Sat Jul 19, 2008 9:28 am

loachman wrote:Hi,

Using the settings you suggested. The heap status showed 40 of 256 when trying to parse and run the application.


Run?
Do you open some of your form in GWT Designer visual editor?
Or you really run your GWT application?

For run you should set memory for your launch configuration, see attached.
For GWT 1.5 default 64m heap is not enough, I set at least 128m.

loachman wrote:I am using java 1.5.0_16 as my jdk, wonder if I should try a different one, or try eclipse 3.3.x again maybe.


I use Java6 and Eclipse 3.4 release.
Attachments
Screenshot - 19.07.2008 , 21_43_40.png
128m for launching GWT 1.5 application
Screenshot - 19.07.2008 , 21_43_40.png (49.38 KiB) Viewed 2404 times
Konstantin.Scheglov
Moderator
 
Posts: 186
Joined: Tue Oct 18, 2005 8:11 pm
Location: Russian Federation, Lipetsk

Re: Memory errors

Postby loachman » Sat Jul 19, 2008 12:16 pm

That worked the magic.

Thanks
loachman
 
Posts: 22
Joined: Thu May 15, 2008 10:02 am

Re: Memory errors

Postby Eric Clayberg » Sun Jul 20, 2008 4:24 pm

I'm glad that worked for you.
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA

Re: Memory errors

Postby eduxativa » Thu Jul 31, 2008 12:26 am

Konstantin.Scheglov wrote:
loachman wrote:Maybe I spoke too soon.
I am using the beta release.

[cut]

I put the following into the eclipse.ini my computer has 512MB of ram (well this particular box anyways)
--launcher.XXMaxPermSize
512m
-vmargs
-Xms40m
-Xmx512m


Can you check that your Eclipse/JVM is really configured for enough memory?
Turn ON "Show heap status" in Window | Preferences | General and check max memory limit, also look how it is changed during parsing.

I use following JVM args "-XX:MaxPermSize=128m -Xms256m -Xmx256m" and this is more than enough to open simple GWT module (but with EXT GWT library attached, so it is also compiled).


Hi, i have the same problem, i turn on show heap status, but i don't know to check max memory limit, how i can do it please?
i,m using designer 5.1 beta and eclipse 3.4 with 3.3 had the same problem.
sorry for my english...
thanks
eduxativa
 
Posts: 5
Joined: Wed Jul 30, 2008 9:39 am

Re: Memory errors

Postby Eric Clayberg » Thu Jul 31, 2008 8:43 am

eduxativa wrote:i don't know to check max memory limit, how i can do it please?

The max memory limit used by Eclipse is whatever you set it to in the Eclipse startup parameters (typically set in the eclipse.ini file).
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA

Re: Memory errors

Postby eduxativa » Thu Jul 31, 2008 9:15 am

Eric Clayberg wrote:
eduxativa wrote:i don't know to check max memory limit, how i can do it please?

The max memory limit used by Eclipse is whatever you set it to in the Eclipse startup parameters (typically set in the eclipse.ini file).


-startup
plugins\org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar
--launcher.library
plugins\org.eclipse.equinox.launcher.win32.win32.x86_1.0.100.v20080509-1800
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
-vmargs
-Xms256m
-Xmx256m


this is my .ini file

But i have the same problem

[ERROR] Failure to load module 'com.mycompany.project.ImageViewer'
java.lang.OutOfMemoryError: Java heap space
at org.eclipse.jdt.internal.compiler.Compiler.handleInternalException(Compiler.java:459)
at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:411)
at com.google.gwt.dev.javac.JdtCompiler.doCompile(JdtCompiler.java:275)
at com.google.gwt.dev.javac.JdtCompiler.compile(JdtCompiler.java:194)
at com.google.gwt.dev.javac.CompilationState.compile(CompilationState.java:72)
at com.google.gwt.dev.cfg.ModuleDef.updateTypeOracle(ModuleDef.java:477)
at com.google.gwt.dev.cfg.ModuleDef.getTypeOracle(ModuleDef.java:324)
at com.google.gwt.dev.GWTShell$BrowserWidgetHostImpl.createModuleSpaceHost(GWTShell.java:253)
at com.google.gwt.dev.shell.ie.BrowserWidgetIE6$External.gwtOnLoad(BrowserWidgetIE6.java:67)
at com.google.gwt.dev.shell.ie.BrowserWidgetIE6$External.invoke(BrowserWidgetIE6.java:128)
at com.google.gwt.dev.shell.ie.IDispatchImpl.Invoke(IDispatchImpl.java:294)


[ERROR] Out of memory; to increase the amount of memory, use the -Xmx flag at startup (java -Xmx128M ...)
eduxativa
 
Posts: 5
Joined: Wed Jul 30, 2008 9:39 am

Next

Return to GWT Designer

Who is online

Users browsing this forum: No registered users and 3 guests