Hi fabio, RequestFactory is great if you have complex data structures (and lots of them) to pass back and forth between the client and the server. It does take more boilerplate to get simple things done, but once you pass a certain threshold of complexity it pays off big, because it will serialize your object graph for you (and give you complete control about what is actually sent over the wire.)
RF also has support for request batching, reducing http request to the server. Another benefit is that it integrates support for BeanValidation. And it also works with the Editor framework, which makes data binding on the client much less tedious. A few comments inline: On Sun, Apr 8, 2012 at 4:24 AM, fabio <[email protected]> wrote: > Hello Daniel > > Let me be explain (maybe some of my assumptions are wrong, so don't hesitate > to correct me :-) ): > > The extra plumbing is pretty heavy, one extra interface for each entity you > want to pass > No compile-time checking between properties in the enity and in the client > interfaces (but maybe the GWT plugins in Eclipse emit some warnings ?) Incorrect. RF will validate your proxy and request interfaces for you at compile time. See http://code.google.com/p/google-web-toolkit/wiki/RequestFactoryInterfaceValidation > You cannot return from the same call "normal" POJO objects and > RequestFcatory Serialized Ones On the client side, all request factory serializable objects extend BaseProxy and are simple interfaces. You can return pojos and entities in a single request, but you have to have define a ValueProxy interface for your pojos and EntityProxy for your entities. > It makes the whole RPC stacks in GWT feel unclear. Too many ways to achieve > the same goal. Ideally I would have a prefer a single way (the legacy > GWT-RPC) that coud have been customized through parameter annotations to > alter the way serialization occurs by default. I think the GWT team has made > great efforts to solve commonly encountered issues with GWT-RPC but they > have lost the magic and beauty of their initial design in the process. RF is not meant to replace GWT-RPC, which I think is still better for simpler use cases. But, for heavily "data-oriented" services, RF (in conjunction with the Editor framework) wins. Jesse -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
