REST Payload API Versioning


In the last few days my focus has been on NoSQL DB(s) and REST services.

Points I’m more interested into are:

  • Payload API versioning
  • Platform independent Payload serialization and / or compression

I found on stackoverflow a very interesting debate on the versioning aspect.

Although exposing the API version in the URI gives great readability and control, I’m still a supporter of the media type field in the header.

I’ve initialized a github project so to realize a few PoC about the subjects I’m studying.

Examples make use of Jersey and Grizzly2 as container for tests. Everything is glued up with Spring 3.0 and built with Maven.

The code includes examples around:

  • Plain Json
  • Compressed (gzip) Json
  • Protocol buffer

You can dowload the code from github with the following command:

git clone https://github.com/nemo83/webservices.git

Any feedback is welcome.

Leave a comment