Sunday, September 28, 2008

SOA and Web Service Versioning

One of the most important you can do when developing a new Web Service is to devise a way to implement versioning. The worst thing you can do is paint yourself into a corner by not doing so. If you don't, your clients will be too tightly coupled with your service and they'll be forced to update their client code and every time you update yours.

There are some simple ways to do so.

1. Use a new URL for new versions of your service and deprecate older URLs.
2. Use optional data types in your schemas as you add new data types over time.
3. Use a coarse grained request mechanism where the client can specify which data types to return. Over time, you can add more data types without affecting your older clients' deprecated data types. This mechanism is especially useful if your service is a content driven service like a destination content service or a mapping service.

No comments: