So I ran into an interesting issue today and I wanted to share it because I 
didn't find an explanation anywhere on the internet.
I'm not sure this issue require a fix but still it was annoying to ran into.

So today, my GWT application (GWT 2.7) didn't want to start for no obvious 
reason (in Debug mode or SDM). Right after the server started, I got the 
famous:
com.google.gwt.user.client.rpc.SerializationException: Type 'MyClass' was 
not assignable to 'com.google.gwt.user.client.rpc.IsSerializable'

Since I didn't have any modified files and that it was working fine 30mn 
before, I knew it was not a code issue. So I cleared all my caches and 
tried again but still no luck. I checked my deployed folder and the gwt.rpc 
file was there and correct.

Then I dug into GWT and found out that my application was using the 
LegacySerializationPolicy (hence the SerializationException).

Turns out, I had forgotten to close the browser tab of a previous SDM 
instance and even though I killed it from my IDE, my application was still 
running in the browser.
In our application we send request every 10s to check for update. So when I 
started my server, a request was received *before* the gwt.rpc file was 
built (and put into the deployment folder), and since GWT couldn't find 
this file it was using the LegacySerializationPolicy and was caching it in 
memory, so GWT would never use my gwt.rpc file...

Conclusion: Never forget to close the browser tab. :)

Cheers

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

Reply via email to