美文网首页
RFC2616 HTTP

RFC2616 HTTP

作者: ljt001 | 来源:发表于2023-12-14 13:17 被阅读0次

    RFC 2616 HTTP
    HTTP 响应码 | MDN
    PUT
    PATCH
    HTTP CORS

    IETF

    国际互联网工程任务组(The Internet Engineering Task Force,简称 IETF)是一个公开性质的大型民间国际团体,汇集了与互联网架构和互联网顺利运作相关的网络设计者、运营者、投资人和研究人员,并欢迎所有对此行业感兴趣的人士参与。
    https://www.ietf.org/topics/

    RFC

    RFC是Request For Comments的缩写,意为“征求意见稿”。它是互联网工程任务组(IETF)的主要工作方式之一。

    RFC2616 主要内容为http协议,https://datatracker.ietf.org/doc/html/rfc2616
    RFC3986关于URI的语法结构说明更清晰:https://datatracker.ietf.org/doc/html/rfc3986#section-3
    URI = scheme ":" hier-part [ "?" query ] [ "#" fragment ]

       The following are two example URIs and their component parts:
             foo://example.com:8042/over/there?name=ferret#nose
             \_/   \______________/\_________/ \_________/ \__/
              |           |            |            |        |
           scheme     authority       path        query   fragment
              |   _____________________|__
             / \ /                        \
             urn:example:animal:ferret:nose
    

    POST/PUT/PATCH

    PATCH更新部分资源,非幂等(不必幂等)。
    PUT更新整个资源,幂等(多次请求结果一样)。
    POST非幂等,可能会有额外作用,比如多次操作可能会新增多个资源或修改多次资源。

    The HTTP PATCH request method applies partial modifications to a resource.
    A PATCH request is considered a set of instructions on how to modify a resource. Contrast this with PUT; which is a complete representation of a resource.
    A PATCH is not necessarily idempotent, although it can be. Contrast this with PUT; which is always idempotent. The word "idempotent" means that any number of repeated, identical requests will leave the resource in the same state.

    The HTTP PUT request method creates a new resource or replaces a representation of the target resource with the request payload.
    The difference between PUT and POST is that PUT is idempotent: calling it once or several times successively has the same effect (that is no side effect), whereas successive identical POST requests may have additional effects, akin to placing an order several times.

    The HTTP POST method sends data to the server.

    相关文章

      网友评论

          本文标题:RFC2616 HTTP

          本文链接:https://www.haomeiwen.com/subject/faltcdtx.html