What is the difference between HTTP and REST?

前端 未结 12 937
南方客
南方客 2020-11-28 00:01

After reading a lot about the differences between REST and SOAP, I got the impression that REST is just another word for HTTP. Can someone explain what functionality REST ad

12条回答
  •  一个人的身影
    2020-11-28 00:40

    Not quite...

    http://en.wikipedia.org/wiki/Representational_State_Transfer

    REST was initially described in the context of HTTP, but is not limited to that protocol. RESTful architectures can be based on other Application Layer protocols if they already provide a rich and uniform vocabulary for applications based on the transfer of meaningful representational state. RESTful applications maximise the use of the pre-existing, well-defined interface and other built-in capabilities provided by the chosen network protocol, and minimise the addition of new application-specific features on top of it.

    http://www.looselycoupled.com/glossary/SOAP

    (Simple Object Access Protocol) The standard for web services messages. Based on XML, SOAP defines an envelope format and various rules for describing its contents. Seen (with WSDL and UDDI) as one of the three foundation standards of web services, it is the preferred protocol for exchanging web services, but by no means the only one; proponents of REST say that it adds unnecessary complexity.

提交回复
热议问题