Changeset 1925 for draft-ietf-httpbis
- Timestamp:
- 01/10/12 08:58:32 (11 years ago)
- Location:
- draft-ietf-httpbis/latest
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
draft-ietf-httpbis/latest/p2-semantics.html
r1924 r1925 600 600 </li> 601 601 <li><a href="#rfc.section.3.1.4">3.1.4</a> <a href="#identification">Identification</a><ul> 602 <li><a href="#rfc.section.3.1.4.1">3.1.4.1</a> <a href="#identifying.payload">Identifying the Payload</a></li>602 <li><a href="#rfc.section.3.1.4.1">3.1.4.1</a> <a href="#identifying.payload">Identifying a Representation</a></li> 603 603 <li><a href="#rfc.section.3.1.4.2">3.1.4.2</a> <a href="#header.content-location">Content-Location</a></li> 604 604 </ul> … … 881 881 </p> 882 882 <p id="rfc.section.3.p.2">For the purposes of HTTP, a <dfn>representation</dfn> is information that reflects the current or desired state of a given resource, in a format that can be readily communicated 883 via the protocol, consisting of a set of metadata (representation header fields) and a potentially unbounded stream of octets 884 (representation data). 883 via the protocol, consisting of a set of representation metadata and a potentially unbounded stream of representation data. 885 884 </p> 886 885 <h2 id="rfc.section.3.1"><a href="#rfc.section.3.1">3.1</a> <a id="representation.metadata" href="#representation.metadata">Representation Metadata</a></h2> … … 1106 1105 </p> 1107 1106 <h3 id="rfc.section.3.1.4"><a href="#rfc.section.3.1.4">3.1.4</a> <a id="identification" href="#identification">Identification</a></h3> 1108 <h4 id="rfc.section.3.1.4.1"><a href="#rfc.section.3.1.4.1">3.1.4.1</a> <a id="identifying.payload" href="#identifying.payload">Identifying the Payload</a></h4>1107 <h4 id="rfc.section.3.1.4.1"><a href="#rfc.section.3.1.4.1">3.1.4.1</a> <a id="identifying.payload" href="#identifying.payload">Identifying a Representation</a></h4> 1109 1108 <p id="rfc.section.3.1.4.1.p.1">When a complete or partial representation is transferred in a message payload, it is often desirable for the sender to supply, 1110 or the recipient to determine, an identifier for theresource corresponding to that representation.1109 or the recipient to determine, an identifier for a resource corresponding to that representation. 1111 1110 </p> 1112 1111 <p id="rfc.section.3.1.4.1.p.2">The following rules are used to determine such a URI for the payload of a request message: </p> … … 1138 1137 <div id="rfc.iref.c.6"></div> 1139 1138 <h4 id="rfc.section.3.1.4.2"><a href="#rfc.section.3.1.4.2">3.1.4.2</a> <a id="header.content-location" href="#header.content-location">Content-Location</a></h4> 1140 <p id="rfc.section.3.1.4.2.p.1">The "Content-Location" header field supplies a URI that can be used as a specific identifier for the representation in this1141 message . In other words, if one were to perform a GET on this URI at the time of this message's generation, then a <a href="#status.200" class="smpl">200 (OK)</a> response would contain the same representation that is enclosed as payload in this message.1139 <p id="rfc.section.3.1.4.2.p.1">The "Content-Location" header field references a URI that can be used as a specific identifier for the representation in this 1140 message payload. In other words, if one were to perform a GET on this URI at the time of this message's generation, then a <a href="#status.200" class="smpl">200 (OK)</a> response would contain the same representation that is enclosed as payload in this message. 1142 1141 </p> 1143 1142 <div id="rfc.figure.u.14"></div><pre class="inline"><span id="rfc.iref.g.14"></span> <a href="#header.content-location" class="smpl">Content-Location</a> = <a href="#imported.abnf" class="smpl">absolute-URI</a> / <a href="#imported.abnf" class="smpl">partial-URI</a> … … 1145 1144 body parts in <a href="http://tools.ietf.org/html/rfc2557#section-4">Section 4</a> of <a href="#RFC2557" id="rfc.xref.RFC2557.1"><cite title="MIME Encapsulation of Aggregate Documents, such as HTML (MHTML)">[RFC2557]</cite></a>. However, its appearance in an HTTP message has some special implications for HTTP recipients. 1146 1145 </p> 1147 <p id="rfc.section.3.1.4.2.p.4">If Content-Location is included in a response message and its value is the same as the effective request URI, then the response1148 payload <em class="bcp14">SHOULD</em> be considered a current representation of that resource. For a GET or HEAD request, this is the same as the default semantics1146 <p id="rfc.section.3.1.4.2.p.4">If Content-Location is included in a <a href="#status.2xx" class="smpl">2xx (Successful)</a> response message and its value refers (after conversion to absolute form) to a URI that is the same as the effective request 1147 URI, then the response payload <em class="bcp14">SHOULD</em> be considered a current representation of that resource. For a GET or HEAD request, this is the same as the default semantics 1149 1148 when no Content-Location is provided by the server. For a state-changing request like PUT or POST, it implies that the server's 1150 1149 response contains the new representation of that resource, thereby distinguishing it from representations that might only … … 1152 1151 need for a subsequent GET request. 1153 1152 </p> 1154 <p id="rfc.section.3.1.4.2.p.5">If Content-Location is included in a response message and its value differs from the effective request URI, then the origin 1155 server is informing recipients that this representation has its own, presumably more specific, identifier. For a GET or HEAD 1156 request, this is an indication that the effective request URI identifies a resource that is subject to content negotiation 1157 and the selected representation for this response can also be found at the identified URI. For other methods, such a Content-Location 1158 indicates that this representation contains a report on the action's status and the same report is available (for future access 1159 with GET) at the given URI. For example, a purchase transaction made via a POST request might include a receipt document as 1160 the payload of the <a href="#status.200" class="smpl">200 (OK)</a> response; the Content-Location value provides an identifier for retrieving a copy of that same receipt in the future. 1161 </p> 1153 <p id="rfc.section.3.1.4.2.p.5">If Content-Location is included in a <a href="#status.2xx" class="smpl">2xx (Successful)</a> response message and its field-value refers to a URI that differs from the effective request URI, then the origin server claims 1154 that the field-value is an identifier for the payload's representation. Such a claim can only be trusted if both identifiers 1155 share the same resource owner, which cannot be programmatically determined via HTTP. 1156 </p> 1157 <ul> 1158 <li>For a response to a GET or HEAD request, this is an indication that the effective request URI identifies a resource that is 1159 subject to content negotiation and the Content-Location field-value is a more specific identifier for the selected representation. 1160 </li> 1161 <li>For a <a href="#status.201" class="smpl">201 (Created)</a> response to a state-changing method, a Content-Location field-value that is identical to the <a href="#header.location" class="smpl">Location</a> field-value indicates that this payload is a current representation of the newly created resource. 1162 </li> 1163 <li>Otherwise, such a Content-Location indicates that this payload is a representation reporting on the requested action's status 1164 and that the same report is available (for future access with GET) at the given URI. For example, a purchase transaction made 1165 via a POST request might include a receipt document as the payload of the <a href="#status.200" class="smpl">200 (OK)</a> response; the Content-Location field-value provides an identifier for retrieving a copy of that same receipt in the future. 1166 </li> 1167 </ul> 1162 1168 <p id="rfc.section.3.1.4.2.p.6">If Content-Location is included in a request message, then it <em class="bcp14">MAY</em> be interpreted by the origin server as an indication of where the user agent originally obtained the content of the enclosed 1163 1169 representation (prior to any subsequent modification of the content by that user agent). In other words, the user agent is … … 1174 1180 to respond to later requests on that Content-Location URI. 1175 1181 </p> 1176 <p id="rfc.section.3.1.4.2.p.9">If the Content-Location value is a partial URI, the partial URI is interpreted relative to the effective request URI.</p>1177 1182 <h2 id="rfc.section.3.2"><a href="#rfc.section.3.2">3.2</a> <a id="representation.data" href="#representation.data">Representation Data</a></h2> 1178 1183 <p id="rfc.section.3.2.p.1">The representation data associated with an HTTP message is either provided as the payload body of the message or referred … … 3260 3265 code (e.g., combinations of request header fields and/or method(s)) along with any dependencies on response header fields 3261 3266 (e.g., what fields are required and what fields can modify the semantics). A response that can transfer a payload ought to 3262 specify expected cache behavior (e.g., cacheability and freshness criteria, as described in <a href="#Part6" id="rfc.xref.Part6.17"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Caching">[Part6]</cite></a>) and whether the payload has any implied association with an identified resource (<a href="#identifying.payload" title="Identifying the Payload">Section 3.1.4.1</a>).3267 specify expected cache behavior (e.g., cacheability and freshness criteria, as described in <a href="#Part6" id="rfc.xref.Part6.17"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Caching">[Part6]</cite></a>) and whether the payload has any implied association with an identified resource (<a href="#identifying.payload" title="Identifying a Representation">Section 3.1.4.1</a>). 3263 3268 </p> 3264 3269 <h3 id="rfc.section.9.2.3"><a href="#rfc.section.9.2.3">9.2.3</a> <a id="status.code.registration" href="#status.code.registration">Registrations</a></h3> -
draft-ietf-httpbis/latest/p2-semantics.xml
r1924 r1925 285 285 that reflects the current or desired state of a given resource, in a format 286 286 that can be readily communicated via the protocol, consisting of a set of 287 metadata (representation header fields) and a potentially unbounded stream288 of octets (representation data).287 representation metadata and a potentially unbounded stream of 288 representation data. 289 289 </t> 290 290 … … 698 698 <section title="Identification" anchor="identification"> 699 699 700 <section title="Identifying the Payload" anchor="identifying.payload">700 <section title="Identifying a Representation" anchor="identifying.payload"> 701 701 <t> 702 702 When a complete or partial representation is transferred in a message 703 703 payload, it is often desirable for the sender to supply, or the recipient 704 to determine, an identifier for theresource corresponding to that704 to determine, an identifier for a resource corresponding to that 705 705 representation. 706 706 </t> … … 753 753 <x:anchor-alias value="Content-Location"/> 754 754 <t> 755 The "Content-Location" header field supplies a URI that can be used756 as a specific identifier for the representation in this message .755 The "Content-Location" header field references a URI that can be used 756 as a specific identifier for the representation in this message payload. 757 757 In other words, if one were to perform a GET on this URI at the time 758 758 of this message's generation, then a <x:ref>200 (OK)</x:ref> response would … … 771 771 </t> 772 772 <t> 773 If Content-Location is included in a response message and its value 774 is the same as the effective request URI, then the response payload 775 &SHOULD; be considered a current representation of that resource. 773 If Content-Location is included in a <x:ref>2xx (Successful)</x:ref> 774 response message and its value refers (after conversion to absolute form) 775 to a URI that is the same as the effective request URI, then the response 776 payload &SHOULD; be considered a current representation of that resource. 776 777 For a GET or HEAD request, this is the same as the default semantics 777 778 when no Content-Location is provided by the server. For a state-changing … … 783 784 </t> 784 785 <t> 785 If Content-Location is included in a response message and its value 786 differs from the effective request URI, then the origin server is 787 informing recipients that this representation has its own, presumably 788 more specific, identifier. For a GET or HEAD request, this is an 789 indication that the effective request URI identifies a resource that 790 is subject to content negotiation and the selected representation for 791 this response can also be found at the identified URI. For other 792 methods, such a Content-Location indicates that this representation 793 contains a report on the action's status and the same report is 794 available (for future access with GET) at the given URI. For 795 example, a purchase transaction made via a POST request might 796 include a receipt document as the payload of the <x:ref>200 (OK)</x:ref> 797 response; the Content-Location value provides an identifier for retrieving 798 a copy of that same receipt in the future. 786 If Content-Location is included in a <x:ref>2xx (Successful)</x:ref> 787 response message and its field-value refers to a URI that differs from the 788 effective request URI, then the origin server claims that the field-value 789 is an identifier for the payload's representation. Such a claim can only be 790 trusted if both identifiers share the same resource owner, which cannot be 791 programmatically determined via HTTP. 792 <list style="symbols"> 793 <t>For a response to a GET or HEAD request, this is an indication that the 794 effective request URI identifies a resource that is subject to content 795 negotiation and the Content-Location field-value is a more specific 796 identifier for the selected representation.</t> 797 <t>For a <x:ref>201 (Created)</x:ref> response to a state-changing method, 798 a Content-Location field-value that is identical to the 799 <x:ref>Location</x:ref> field-value indicates that this payload is a 800 current representation of the newly created resource.</t> 801 <t>Otherwise, such a Content-Location indicates that this payload is a 802 representation reporting on the requested action's status and that the 803 same report is available (for future access with GET) at the given URI. 804 For example, a purchase transaction made via a POST request might 805 include a receipt document as the payload of the <x:ref>200 (OK)</x:ref> 806 response; the Content-Location field-value provides an identifier for 807 retrieving a copy of that same receipt in the future.</t> 808 </list> 799 809 </t> 800 810 <t> … … 827 837 different from the URI used to retrieve it can be used to respond to 828 838 later requests on that Content-Location URI. 829 </t>830 <t>831 If the Content-Location value is a partial URI, the partial URI is832 interpreted relative to the effective request URI.833 839 </t> 834 840 </section>
Note: See TracChangeset
for help on using the changeset viewer.