It depends. RequestBuilder is basically a wrapper around XMLHTTPRequest. It can be used but IMHO I would use one of the high level abstractions which are:
GWT RPC is the easiest to get started but you will have stronlgy coupling between backend and frontend and there are some pitfalls (if you update the RPC code on the backend, you have to cope with seralizations errors from clients with outdated versions of the frontend code) you have to be aware of. RequestFactory is another choice which supports transferring only deltas (things that changed). This is quite handy for CRUD like applications. However like RPC you will have strong coupling between backend/frontend. Both GWT-RCP and RF works if you use Java on the backend (theoratically you could use it with another language on the backend, but you would have to implement the backend logic yourself). Errai provides various communcation protocols (EventBus, JAX-RS, RPC). Again this will lead to a stronger coupling between backend and frontend (maybe with the exception of JAX-RS). But In general Errai is quite easy to use. Finally you could use a Restful approach. This is best if you want to want to de-couple your frontend from your backend (For example if you want to use the same backend from other non-GWT clients: Android, etc).This might be more involved than the above solutions (although RestyGWT provides a nice abstractions) but I would recommend it as it provides a lot of flexibility and you can evolve your backend independently from your frontend. On Monday, February 9, 2015 at 1:41:03 PM UTC+1, Mohammed Sameen wrote: > > Hi, > I created big application using GWT and am using RequestBuilder to > communicate with the server.So what is the best way for communicate to > server from client. > i)RequestBuilder > ii)GWT RPC > iii)Any other approach(GWT Errai). > > > I came to know that using GWT RPC is huge pain , so,what are the drawback > of using GWT RPC?what is the best approach?Please give me suggestion? > -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
