简体   繁体   中英

GWT on GAE application with Web Services

I'm interested in building a Google Web Toolkit (GWT) application that will run on the Google App Engine (GAE). I'd also like to expose a web service that shares the same datastore and can receive posted data from a different web application hosted elsewhere.

Would using Restlet be a good solution, or is there a simpler approach that doesn't require the use of a 3rd party library? Is there some way for the GWT client to accepted json that can then be serialised over GWT-RPC to the GAE datastore? Do I need to write a servlet that can parse and persist jsonp?

I suspect my thinking may be a bit muddled here... any assistance is appreciated!

As per http://groups.google.com/group/google-appengine-java/web/will-it-play-in-app-engine

Restlet Version(s): 2.0 M5 + Status: COMPATIBLE The team has created an adaptation of Restlet just for App Engine. See http://wiki.restlet.org/developers/172-restlet/251-restlet.html for instructions on tuning a standard installation of Restlet for App Engine.
Here's another blog post from the team about Restlet: http://blog.noelios.com/2009/04/11/restlet-in-the-cloud-with-google-app-engine/

GWT has native support for JSON, You just need a library on the server to parse/create JSON. ( GWT JSON Sample )

GAE uses Servlets, so any Servlet would do if you wanted to go that route. There is nothing to say that your client needs to be GWT.

You can use the persistence JDO, JPA or Raw APIs for persistence, They are a little tricky and not that clearly documented (it is complex).
See these articles for a clear explanation and sample code:
http://www.ibm.com/developerworks/java/library/j-gaej1/
http://www.ibm.com/developerworks/java/library/j-gaej2/index.html
http://www.ibm.com/developerworks/java/library/j-gaej3.html

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM