Home > Android > Android and Web Services

Android and Web Services

Google recommends using RESTful Web services.It increases performance.  Because REST defines architectural design that focuses on system’s resources.

REST Web service follows four basic design principles

  • USE HTTP methods explicitly. CRUD operations should have one -to-one correspondance with HTTP supported operation i.e, GET, POST, PUT & DELETE.
  1. To create a resource on the server , use POST.
  2. To retrieve a resource, use GET.
  3. To change the state of  a resource or to update it, use PUT.
  4. To remove or delete a resource, use DELETE
  • Be stateless ( it improves performance by saving bandwidth and minimizing  server side application state).
  • Expose directory structure-like URIs. The structure of a URI should be straightforward, predictable, and easily understood.
  • Transfer XML, JavaScript Object Notation (JSON), or both. This allows the service to be used by a variety of clients written in different languages running on different platforms and devices.

Reference: http://www.ibm.com/developerworks/webservices/library/ws-restful/

Thanks.

Advertisements
Categories: Android
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: