Struts2のGWT用プラグインの問題
現在Struts2とGWTの連携用に Google Code Archive - Long-term storage for Google Code Project Hosting. の 最新版 0.2.1 を利用しているが、このプラグインが開発された当時は GWTは 1.3 で、現在の 1.4 で利用できるRPCのデータ型が IsSerializable では無く、Serializable を実装すればいいという仕様が使えない。
IsSerializable を実装していないと、こんなエラーになる
[WARN] StandardContext[]Exception while dispatching incoming RPC call com.google.gwt.user.client.rpc.IncompatibleRemoteServiceException: Type 'tutorial.client.data.MyRPCData' 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.
このエラーの原因がわからず大分時間がかかったが、結局GWT1.3仕様で Serializableでは無くIsSerializableを実装しなければいけないということが判明した。