views:

147

answers:

2

Ok so I've implemented both REST and SOAP services and I like both depending on the context. For me, WS* is great when I want an explicit contract between the server and the client e.g. for sensitive information or for mission critical stuff. REST on the other hand whilst flexible in terms of the schema definition, is in my mind more ideal for content services or data which is not required to undergo any serious business logic.

REST seems to be very much the flavour of the day, and I was somewhat put out when Martin Fowler et al from Thoughworks gave this podcast: http://www.thoughtworks.com/what-we-say/podcasts.html on REST and were derisive toward WS*. Whilst the man himself is well respected, am I right in thinking that there still is very much a place for SOAP and pinch of salt is required here? And has anyone used REST in a serious business application?

+2  A: 

Can you document your REST api by providing someone a description of the media types you use and a single URL?

If you find yourself providing a list of URLs and what verbs can be used on those URLs then you probably don't have a REST api.

Once you have created a true REST api then go back and compare it to WS* api. You will see they are very different.

REST apis can easily handle "serious business logic" and yes I have used REST in a serious business application.

Darrel Miller
I like the fact that you're highlighting that the use of endpoints is misunderstood/misused in REST. Would still like to know if there is a time and a place for SOAP though...
rjarmstrong
I'm afraid I can't really answer that question, all I can tell you is that in my client/server scenario, REST was far more effective than SOAP.
Darrel Miller
+1  A: 

Diary of a Fence Sitting SOA Geek - Dr Mark Little

Presentation is very recent - pretty revealing stuff.

REST actually works. It's not as good for repeat business as SOAP is. So many consultants fight to save SOAP on that basis. As the tools and frameworks for RESTful architectures improve, businesses will move in that direction. Governance is big talk at the moment also.

The new version of JAX-RS is a pretty interesting new tool for RESTful dev, Mark Little mentions this in his presentation.

You're probably better off considering SOAP as legacy technology, it'll serve you better going forward. ;)

Mike K