RESTful application on Google App Engine Java?

后端 未结 10 1848
轻奢々
轻奢々 2020-12-22 15:43

I would like to create a RESTful app on Google App Engine. I would like to provide XML and JSON services. I have briefly experimented with Restlet, Resteasy, and Jersey. I h

相关标签:
10条回答
  • 2020-12-22 15:47

    Since these valiant older solutions were patched together, Google has apparently supplied an Eclipse plugin to create a starter project that produces an App Engine app, an Android APK, and a Web app, all talking to one another over an interface defined by a single set of annotated object declarations.

    Haven't tried this yet myself, but do have a look before trying any of the more heterogeneous examples described in the earlier messages above:

    https://developers.google.com/eclipse/docs/appengine_connected_android

    This Google video is also quite informative:

    http://www.youtube.com/watch?v=NU_wNR_UUn4

    0 讨论(0)
  • 2020-12-22 15:50

    For what it's worth, there has been quite a bit of discussion on Jersey user lists wrt how to make Jersey work on GAE. It is bit tedious work due to GAE restrictions (missing classes from white lists -- hopefully resolved over time), but apparently can be made to work. So while not trivially easy, that might be your best bet; esp. since many of the problems faced are the same for all frameworks (imposed by GAE).

    0 讨论(0)
  • 2020-12-22 15:50

    I recently put together a project template with Jersey, Guice and AppEngine at GitHub. It has been developed with SimpleDS, but it can be modified to work with Objectify / JDO easily. The project is live here.

    It should be a good starting point for new projects.

    0 讨论(0)
  • 2020-12-22 15:50

    The 2 most cumbersome GAE REST API actions to make work, whether Java or .py, are graphics and how to undisplay private information. My little gae rest feed forked another project. I'm sure Java succeeds where python stuck due to the Java takes and gives more ways (advantages) as well as longer (slower) time to succeed (disadvantage) while python projects opens less ways to succeed (disadvantageous) and less development time (advantageous rapid development) to succeed the same.

    0 讨论(0)
  • 2020-12-22 15:51

    I'm using Jersey on GAE. Here is the link for those who are interested about setting it up: (I'm using GAE SDK v1.4.0):

    http://tugdualgrall.blogspot.com/2010/02/create-and-deploy-jax-rs-rest-service.html

    0 讨论(0)
  • 2020-12-22 15:56

    Here is a very very good tutorial Restlet/Android/GAE/Objectify with an example of a simple application. Sorry it's in french, but you can juste copy/paste the code, or use google traduction.

    I followed it and had a working Android / GAE server communicating together in a 2 hours. It's a good base to start or test Restlet.

    http://www.tutos-android.com/webservice-rest-android-appengine-restlet-objectify

    Good Luck

    0 讨论(0)
提交回复
热议问题