Restful versus SOAP–Is SOAP Obsolete?

REST is obviously taking over the world of web services. However, there are several vendors still pushing out SOAP compliant APIs and providing services that are SOAP based. The reason for this is many-fold.

Atomicity and Transactions

Only SOAP, through WS-AtomicTransaction provides complete ACID in the web service world.

Security

In addition to standard SSL  support, SOAP provides WS-SEcurity options. These can be thought of as message level security (encrypting parts of the soap message), as opposed to transport level security (which SSL provides).

One might ask, why do we need message level encryption when the entire transit is encrypted at the network level?  That’s just the point – SSL takes care of in-transit encryption – but the actual soap message is unencrypted. If, for instance, your web traffic is routed through a proxy server, the SOAP message is decrypted at the proxy – which means it passes into your network in plain text.

Advantages of REST

In a nutshell, simplicity is the biggest advantage of REST. REST doesn’t require a complex interface description language (SOAP requires WSDL). REST works with just XML or JSON (JavaScript Object Notation) and several other media types.

REST is also better performing (reads can be cached, for example) and scales easily. Amazon (and eBay) are primarily REST based.

Summary

For an enterprise grade SOA that requires both Transactionality (between successive message calls) and Security (message level security), SOAP is still more powerful  than REST. If these advanced security and transactionality features are ‘optional’, you may be better off with RESTFul services.

Specializing in high volume web and cloud application architecture, Anuj Varma’s customer base includes Fortune 100 companies (dell.com, British Petroleum, Schlumberger).
Anuj also offers a 1-day ‘technology for executives, crash course’ focused on emerging technologies.
For Anuj’s specialized one-on-one executive seminars, visit ANUJ.COM
All content on this site is original and owned by anujvarma.com.

Anuj Varma – who has written posts on Anuj Varma, Technology Architect.


Leave a Reply

Your email address will not be published. Required fields are marked *