SOAP | REST |
SOAP clients call every SOAP operation on the server using only Http GET | REST clients leverage true functionality of HTTP methods like GET,POST,PUT and DELETE and use them to call the REST service |
SOAP is operation centric | REST is resource centric |
SOAP mandates the use of WSDL and proxies on all the clients which need to call SOAP web service | REST call be called from any client on any platform with using any proxy or WSDL |
If SOAP WS Interface changes, you need to update proxies on the all clients which are hooked to that SOAP WS | REST services doesn't have this limitation |
SOAP puts overhead of and on the XML data | REST doesn't put any such overhead |
Stateful SOAP services are not scalable | REST services are stateless by design so they are scalable |
Stateful SOAP services create much headache in Load-balanced environment | Because REST is fundamentally stateless, this headache doesn't arises |
SOAP objects are not cache-able | REST Uris are cache-able |
SOAP puts additional overhead of SoapBody and SoapEnvelope which is considerable for low bandwidth clients like PDAs, Smartphones, etc | REST doesn't have this limitation |
SOAP is slower because it consumes time parsing XML and serializing objects | REST is faster because its simpler and doesn't have such schema dependencies |
SOAP has a bigger learning curve as developers need to fully understand WSDL, UDDI, WS-* | REST has very shorter learning curve as it extends directly from HTML |
Despite these limitations SOAP is still the first choice when it comes to Reliable, Secure and Transactional Web Services. So each side has its pros and cons but REST is certainly more than it is thought to be.
No comments:
Post a Comment