GWT Serialization Exceptions (Multiple GWT Modules)

Hey,

I am having an issue where I am getting the following exception when running a GWT hosted mode configuration from IDEA :

gwt.GwtController Call to service method 'reportingService.retrieveListOfReportsWithoutVars()' failed
com.google.gwt.user.client.rpc.SerializationException: Type 'com.osssoftware.reporting.client.valueobjects.ReportVO' was not assignable to 'com.google.gwt.user.client.rpc.IsSerializable' and did not have a custom field serializer.For security purposes, this type will not be serialized.: instance = com.osssoftware.reporting.client.valueobjects.ReportVO:cube(1)
 at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamWriter.serialize(ServerSerializationStreamWriter.java:615)
 at com.google.gwt.user.client.rpc.impl.AbstractSerializationStreamWriter.writeObject(AbstractSerializationStreamWriter.java:126)
 at com.google.gwt.user.client.rpc.core.java.util.Collection_CustomFieldSerializerBase.serialize(Collection_CustomFieldSerializerBase.java:45)
 at com.google.gwt.user.client.rpc.core.java.util.LinkedList_CustomFieldSerializer.serialize(LinkedList_CustomFieldSerializer.java:40)
 at com.google.gwt.user.client.rpc.core.java.util.LinkedList_CustomFieldSerializer.serializeInstance(LinkedList_CustomFieldSerializer.java:50)
 at com.google.gwt.user.client.rpc.core.java.util.LinkedList_CustomFieldSerializer.serializeInstance(LinkedList_CustomFieldSerializer.java:28)
 at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamWriter.serializeImpl(ServerSerializationStreamWriter.java:736)
 at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamWriter.serialize(ServerSerializationStreamWriter.java:617)
 at com.google.gwt.user.client.rpc.impl.AbstractSerializationStreamWriter.writeObject(AbstractSerializationStreamWriter.java:126)




The issue does not exist in production mode when I compile my gwt modules.

I am using Grails, and the ReportVO mentioned sits in a GWT module in a plugin that the Main Module inherits.  This is explained here :

http://grails.1312388.n4.nabble.com/Multiple-GWT-Modules-tp4547590p4549693.html

I was basically able to co-erce the GWT plugin to compile my plugin module along with the main module but I cannot get hosted mode to work properly.

It sounds to me like it is a classpath issue as it is only effecting hosted mode and I need to somehow add the plugin module's server code to the GWT client configuration.

I suppose my question is, can I add the plugin's GWT modules server code to the run configuration for the Main projects GWT module???

Attached an image of project modules.

Attachment(s):
idea.png
2 comments
Comment actions Permalink

hmmm the grails command run-gwt-client seems to work ok, so maybe it is a classpath loading issue....?

0
Comment actions Permalink

Ah, there was a build error in the IDEA build process that was not showing during the grails compile process.

I fixed these issues and got the IDEA "make" working and the it put the server code on the classpath during the process.

All working well now!

0

Please sign in to leave a comment.