GWT IncompatibleRemoteServiceException
Solution 1
I experienced this issue with the jetty in development mode. The problem in my case was that the jetty didnt do a "clean". I removed manually the .jar of my gwt module in workspace/.metadata/.plugins/org.eclipse.wst.server.core/ (e.g. my-module.jar)
After that, the class on the server side and client site were the same again.
Solution 2
In Eclipse, simply Project > Clean... worked for me.
Piers MacDonald
Updated on August 06, 2022Comments
-
Piers MacDonald almost 2 years
Straight forward but maddening, I get this error on my RPC call:
An IncompatibleRemoteServiceException was thrown while processing this call. com.google.gwt.user.client.rpc.IncompatibleRemoteServiceException: Invalid type signature for com.milkrun.core.dto.UserBasket
Here is the class causing the issue:
public class UserBasket implements Serializable{ private static final long serialVersionUID = -6761554796753637352L; public int userBasketID; public String description; public String userID; public List<BasketItem> items; public String createUserId; public Timestamp createTs; public String lastUpdateUserId; public Timestamp lastUpdateTs; public Timestamp effStartTs; public Timestamp effStopTs; }
And the type BasketItem:
public class BasketItem implements Serializable { private static final long serialVersionUID = -17764683871112216L; public int basketItemID; public String upc; public String description; public String brandName; public BigDecimal price; public String createUserId; public Timestamp createTs; public String lastUpdateUserId; public Timestamp lastUpdateTs; public Timestamp effStartTs; public Timestamp effStopTs; }
I'm not sure where I'm going wrong and I'd rather not use IsSerializable as these DTOs are in a project shared by an android app too and IsSerializable is part of the GWT stack.