Jetty hangs/crashes (with "Termination failed") in DevMode after validation

79 views
Skip to first unread message

Bojan Popović

unread,
May 31, 2012, 10:16:20 AM5/31/12
to gwt-val...@googlegroups.com
Hello,

As I started using this library, my Development Mode server gets stuck if I try to do a hot code swap while running it (when I change some code not related to validation and hit F5 in the browser to see changes). Then the browser hangs, and if I try to kill the server in Eclipse i get a "Termination failed" error and Eclipse disconnects from the server (but the port stays bound so I guess the server keeps looping in the background).

I am trying to hunt down the cause of this problem, and am pretty sure it started appearing after I included gwt-validation into the classpath. Also, it does not happen before the first use of the Validator. Could the reflections library be responsible?

Did anyone here experience something similar?

Thx

Reto

unread,
Jun 3, 2012, 12:32:00 PM6/3/12
to gwt-val...@googlegroups.com
Hi, 

if you have lots of classes in your project, the first validation makes my browser hang for about 10s due to class scanning. With the 2nd validation it does not hang anymore as it only scans once.

Regards,
Reto

Bojan Popović

unread,
Jun 4, 2012, 5:03:25 AM6/4/12
to gwt-val...@googlegroups.com
Hi,

Yep, I know this, but my issue is of a more serious nature. After the first validation hangs, and the reflections library does it's thing, the other validation calls are quick. But if I try changing my code (which doesn't necessarily need to be directly related to the validation module in my project), and hit 'refresh' in my browser, the Jetty server hangs indefinitely. If I try to kill it, I get a "Termination aborted" error, and it disconnects from my Eclipse environment but still hangs in the background (I have to kill it from the terminal to unbind the address). 

I think this is a serious problem but it surprised me that no one here in the group has reported such behavior.

Thx for the reply,
Bojan 

Bojan Popović

unread,
Jun 5, 2012, 8:20:51 AM6/5/12
to gwt-val...@googlegroups.com
I seem to have fixed this issue. It was an OutOfMemory error linked with the PermGenSpace part of the JVM heap (as a result of a classloader memory leak, apparently). Extending the size of it enabled clean redeploys in DevMode.

Patrick

unread,
Oct 23, 2012, 12:44:27 PM10/23/12
to gwt-val...@googlegroups.com
Hello Bojan,

I'm having the same problem.
The first time i run a project it hangs the browser for a few seconds and then it works.
Then I work in the project and hit F5 to check the result and it still works 'properly'.
After let's say a dozen F5, I've got this exception wich I think is the same as yours (?) :

java.lang.reflect.invocationTargetException
....
caused by java.langRuntimeException: deferred binding failed for 'com.google.gwt.user.client.UserAgentAsserter$UserAgentProperty' (did you forget to inherit a required module?)
...
caused by: java.langOutOfMemoryError: PermGen space

It's surprising because my project is only a test project and is very small.

I've been trying to extend memory size of the jvm and set it to -Xmx1024m (did you set more?) but after a few testing i still run into the same problem.
I'm very new to GWT (GXT actually in my case) and i'm very disapointed with this problem.
Did it actually solve the problem or did you just stop posting about it?
If yes, how much xmx did you set?

Thank you in advance,
Patrick

ps: I'm having this problem both using the default gwt launch configuration/way and using hotdeploy on a tomcat 7 (that i set up to avoid the problem but it didn't work...).

Patrick

unread,
Oct 23, 2012, 12:58:07 PM10/23/12
to gwt-val...@googlegroups.com
I just tried to set the xmx to 2048 and launch my project monitoring memory use.
At each refresh, the amount of memory used kept growing on 2 java processes until their sum reached 2Go and then crashed with a permgem.


Le mardi 5 juin 2012 14:20:51 UTC+2, Bojan Popović a écrit :
Reply all
Reply to author
Forward
0 new messages