GWT RPC Serialization on web and app server

2671 views
Skip to first unread message

Anky

unread,
Oct 31, 2012, 11:30:39 PM10/31/12
to google-we...@googlegroups.com
Hi All,

I am facing a very strange scenario here. We have a GWT application that runs perfectly fine when deployed on weblogic app server. So far this was going pretty smooth for us. Now we are preparing our app for production release. For that, as per our company standard, we have installed a web server on our integration machine which will communicate with app server (installed on the same integration machine). When we access our application via webserver, we are getting the incompatibleremoteservletexception

We are using Serializable objects instead of IsSerializable for all the RPC calls in our application. This works fine when the application is directly access via the application server.

Your help here would be really appreciated.

----
sample exception stack trace:

com.google.gwt.user.client.rpc.IncompatibleRemoteServiceException: Type 'com.xyz.rpcservices.ABCRequest' 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 deserialized.

        at com.google.gwt.user.server.rpc.RPC.decodeRequest(RPC.java:308)

        at com.google.gwt.user.server.rpc.RemoteServiceServlet.processCall(RemoteServiceServlet.java:186)

        at com.google.gwt.user.server.rpc.RemoteServiceServlet.processPost(RemoteServiceServlet.java:224)

        at com.google.gwt.user.server.rpc.AbstractRemoteServiceServlet.doPost(AbstractRemoteServiceServlet.java:62)

        at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)

        Truncated. see log file for complete stacktrace

com.google.gwt.user.client.rpc.SerializationException: Type 'com.xyz.rpcservices.ABCRequest' 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 deserialized.

        at com.google.gwt.user.server.rpc.impl.LegacySerializationPolicy.validateDeserialize(LegacySerializationPolicy.java:127)

        at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamReader.deserialize(ServerSerializationStreamReader.java:520)

        at com.google.gwt.user.client.rpc.impl.AbstractSerializationStreamReader.readObject(AbstractSerializationStreamReader.java:61)

        at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamReader$ValueReader$8.readValue(ServerSerializationStreamReader.java:137)

        at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamReader.deserializeValue(ServerSerializationStreamReader.java:384)

        Truncated. see log file for complete stacktrace     

Jens

unread,
Nov 1, 2012, 5:27:54 AM11/1/12
to google-we...@googlegroups.com
Make sure that your app server can still find the <HASH>.rpc file. Thats your GWT-RPC serialization policy file that the server must know in order to serialize anything that implements Serializable. If it does not find this file it falls back to the old IsSerializable mechanism and if you do not have implemented that interface serialization will fail. 

Normally you should see a warning in the app server log on the first RPC request when GWT's RemoteServiceServlet tries to load the serialization policy file but can not find it.

For example I often have to change the lookup of that file because my deployment does not conform to GWT's standard assumptions.

-- J.

Benoit GUILLOTIN

unread,
Jan 15, 2014, 8:40:34 AM1/15/14
to google-we...@googlegroups.com
HI Entlog,

How did U fix ur problem on Jmeter with the <HASH>.gwt.rpc file ?
Im still looking for fixing this IncompatibleRemoteServiceException.

Thanks for ur answer.
Benoit

Le jeudi 23 mai 2013 12:30:21 UTC+2, Entlog a écrit :
Awesome!! Thanks. I was having problems with a jmeter test and I saw your solution...it's really that! The jmeter captured request had the reference to the hash for another deployed environment and when trying to test against another deployed war it was throwing the serializable error. Now I know how to fix it :)...

Snehalkumar Rangnenwar

unread,
Jun 5, 2020, 3:33:00 AM6/5/20
to GWT Users
Hey Entlog , 
 what was the solution you applied in jmeter to fix the incompatibility issue ? please let us know as well.

Thank in advance, 
skay

Michael Conrad

unread,
Jun 5, 2020, 12:17:18 PM6/5/20
to google-we...@googlegroups.com
Does your servlet context path exactly match the request path as sent by the browser?
--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/5c9d5947-af97-4b68-892c-b98f52de3033o%40googlegroups.com.

Snehalkumar Rangnenwar

unread,
Jun 8, 2020, 4:57:56 AM6/8/20
to GWT Users
Yes they do match.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsub...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages