GWT deRPC to be Deprecated

by Max Rohde,

Direct evaluate Remote Procedure Calls (deRPCs) in GWT seem to be promising approach to transfer objects from server to browser. Rather than encoding objects into a stream of text in a legacy format, deRPC sends objects as JavaScript statements from server to client.

However, after some time of working with it, two important reasons surfaced not to adopt this technology.

-1- deRPC does not work very well

I had a number of issues in using deRPC:

  • While my test application ran fine in the hosted mode, I was not able to get it working deployed as a WAR onto tomcat and jetty. Debugging with Firebug reveals that the messages send from client to server are identical in hosted mode/deployed but the response send from the server was no JavaScript code in hosted mode (but only in deployed mode – which then was not read correctly by the server). I might of course have configured the whole project incorrectly, but I spent hours on the problem and did not get it fixed.
  • The JavaScript generated by the server, which was sent over the wire (when the application was deployed in a servlet container), seemed to be very verbose.

-2- GWT deRPC is about to be depreacted by the Google GWT team

"DeRPC was created to help with large object graph serialization; however, DeRPC (NOT GWT-RPC) will likely be deprecated eventually in favor of RequestFactory." (David Chandler on Google Groups)

Categories: java