I'm new to GWT and RequestFactory so I'm coding a simple test app using GWT RequestFactory for RPC and Objectify for ORM.
I have a simple Person entity and was able to get all crud operations working fine. I wanted to try adding a value type for storing addresses as an @Embedded property in my Person class, just like it's shown on the Google Developer site. So I added a simple POJO Address, AddressProxy extending ValueProxy, etc.
I end up having adding a couple of lines of code to my RequestFactory call like this:
PersonRequest req = rf.personRequest();
AddressProxy address = req.create(AddressProxy.class); // Added this
address.setCity(city); // this
PersonProxy person = req.create(PersonProxy.class);
person.setName("Joe");
person.setPhone("215-555-1212");
person.setAddress(address); // and this.
req.save(person).fire();
So everything compiles perfectly and stepping through the code everything is A-OK on client side. On the server side, I get UnexpectedExcpetion: No type for token...
Spefically it seems to get caught on this method here under com.google.web.bindery.requestfactory.server.ResolverServiceLayer:
@Override
public Class<? extends BaseProxy> resolveClass(String typeToken) {
String deobfuscated = deobfuscator.getTypeFromToken(typeToken);
if (deobfuscated == null) {
die(null, "No type for token %s", typeToken);
}
I'm assuming it's trying to determine the type from the request context but it's not helping me see what is missing on my end. What would cause this?