Changeset 2238


Ignore:
Timestamp:
May 6, 2013, 11:33:20 PM (6 years ago)
Author:
mnot@…
Message:

Move "Combining Partial Responses" up into "Storing Responses in Caches"; revise title of "Freshening Responses with 304 Not Modified". See #469

Location:
draft-ietf-httpbis/latest
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • draft-ietf-httpbis/latest/p6-cache.html

    r2237 r2238  
    590590               <li><a href="#rfc.section.3.1">3.1</a>&nbsp;&nbsp;&nbsp;<a href="#incomplete.responses">Storing Incomplete Responses</a></li>
    591591               <li><a href="#rfc.section.3.2">3.2</a>&nbsp;&nbsp;&nbsp;<a href="#caching.authenticated.responses">Storing Responses to Authenticated Requests</a></li>
     592               <li><a href="#rfc.section.3.3">3.3</a>&nbsp;&nbsp;&nbsp;<a href="#combining.responses">Combining Partial Content</a></li>
    592593            </ul>
    593594         </li>
     
    601602               </li>
    602603               <li><a href="#rfc.section.4.2">4.2</a>&nbsp;&nbsp;&nbsp;<a href="#validation.model">Validation</a><ul>
    603                      <li><a href="#rfc.section.4.2.1">4.2.1</a>&nbsp;&nbsp;&nbsp;<a href="#freshening.responses">Freshening Responses with 304 Not Modified</a></li>
     604                     <li><a href="#rfc.section.4.2.1">4.2.1</a>&nbsp;&nbsp;&nbsp;<a href="#freshening.responses">Freshening Stored Responses upon Validation</a></li>
    604605                  </ul>
    605606               </li>
    606607               <li><a href="#rfc.section.4.3">4.3</a>&nbsp;&nbsp;&nbsp;<a href="#caching.negotiated.responses">Calculating Secondary Keys with Vary</a></li>
    607                <li><a href="#rfc.section.4.4">4.4</a>&nbsp;&nbsp;&nbsp;<a href="#combining.responses">Combining Partial Content</a></li>
    608608            </ul>
    609609         </li>
     
    845845            (OK)</a> cache entry. However, a cache <em class="bcp14">MUST NOT</em> store incomplete or partial content responses if it does not support the <a href="p5-range.html#header.range" class="smpl">Range</a> and <a href="p5-range.html#header.content-range" class="smpl">Content-Range</a> header fields or if it does not understand the range units used in those fields.
    846846      </p>
    847       <p id="rfc.section.3.1.p.2">A cache <em class="bcp14">MAY</em> complete a stored incomplete response by making a subsequent range request (<a href="#Part5" id="rfc.xref.Part5.1"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Range Requests">[Part5]</cite></a>) and combining the successful response with the stored entry, as defined in <a href="#combining.responses" title="Combining Partial Content">Section&nbsp;4.4</a>. A cache <em class="bcp14">MUST NOT</em> use an incomplete response to answer requests unless the response has been made complete or the request is partial and specifies
     847      <p id="rfc.section.3.1.p.2">A cache <em class="bcp14">MAY</em> complete a stored incomplete response by making a subsequent range request (<a href="#Part5" id="rfc.xref.Part5.1"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Range Requests">[Part5]</cite></a>) and combining the successful response with the stored entry, as defined in <a href="#combining.responses" title="Combining Partial Content">Section&nbsp;3.3</a>. A cache <em class="bcp14">MUST NOT</em> use an incomplete response to answer requests unless the response has been made complete or the request is partial and specifies
    848848         a range that is wholly within the incomplete response. A cache <em class="bcp14">MUST NOT</em> send a partial response to a client without explicitly marking it as such using the <a href="p5-range.html#status.206" class="smpl">206 (Partial Content)</a> status code.
    849849      </p>
     
    857857         a subsequent request without revalidating it on the origin server.
    858858      </p>
     859      <h2 id="rfc.section.3.3"><a href="#rfc.section.3.3">3.3</a>&nbsp;<a id="combining.responses" href="#combining.responses">Combining Partial Content</a></h2>
     860      <p id="rfc.section.3.3.p.1">A response might transfer only a partial representation if the connection closed prematurely or if the request used one or
     861         more Range specifiers (<a href="#Part5" id="rfc.xref.Part5.2"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Range Requests">[Part5]</cite></a>). After several such transfers, a cache might have received several ranges of the same representation. A cache <em class="bcp14">MAY</em> combine these ranges into a single stored response, and reuse that response to satisfy later requests, if they all share the
     862         same strong validator and the cache complies with the client requirements in <a href="p5-range.html#combining.byte.ranges" title="Combining Ranges">Section 4.3</a> of <a href="#Part5" id="rfc.xref.Part5.3"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Range Requests">[Part5]</cite></a>.
     863      </p>
     864      <p id="rfc.section.3.3.p.2">When combining the new response with one or more stored responses, a cache <em class="bcp14">MUST</em>:
     865      </p>
     866      <ul>
     867         <li>delete any <a href="#header.warning" class="smpl">Warning</a> header fields in the stored response with warn-code 1xx (see <a href="#header.warning" id="rfc.xref.header.warning.1" title="Warning">Section&nbsp;7.5</a>);
     868         </li>
     869         <li>retain any <a href="#header.warning" class="smpl">Warning</a> header fields in the stored response with warn-code 2xx; and,
     870         </li>
     871         <li>use other header fields provided in the new response, aside from <a href="p5-range.html#header.content-range" class="smpl">Content-Range</a>, to replace all instances of the corresponding header fields in the stored response.
     872         </li>
     873      </ul>
    859874      <h1 id="rfc.section.4"><a href="#rfc.section.4">4.</a>&nbsp;<a id="constructing.responses.from.caches" href="#constructing.responses.from.caches">Constructing Responses from Caches</a></h1>
    860875      <p id="rfc.section.4.p.1">When presented with a request, a cache <em class="bcp14">MUST NOT</em> reuse a stored response, unless:
     
    10381053         or doing so is explicitly allowed (e.g., by the max-stale request directive; see <a href="#cache-request-directive" title="Request Cache-Control Directives">Section&nbsp;7.2.1</a>).
    10391054      </p>
    1040       <p id="rfc.section.4.1.4.p.4">A cache <em class="bcp14">SHOULD</em> append a <a href="#header.warning" class="smpl">Warning</a> header field with the 110 warn-code (see <a href="#header.warning" id="rfc.xref.header.warning.1" title="Warning">Section&nbsp;7.5</a>) to stale responses. Likewise, a cache <em class="bcp14">SHOULD</em> add the 112 warn-code to stale responses if the cache is disconnected.
     1055      <p id="rfc.section.4.1.4.p.4">A cache <em class="bcp14">SHOULD</em> append a <a href="#header.warning" class="smpl">Warning</a> header field with the 110 warn-code (see <a href="#header.warning" id="rfc.xref.header.warning.2" title="Warning">Section&nbsp;7.5</a>) to stale responses. Likewise, a cache <em class="bcp14">SHOULD</em> add the 112 warn-code to stale responses if the cache is disconnected.
    10411056      </p>
    10421057      <p id="rfc.section.4.1.4.p.5">note that if a cache receives a first-hand response (either an entire response, or a <a href="p4-conditional.html#status.304" class="smpl">304 (Not Modified)</a> response) that it would normally forward to the requesting client, and the received response is no longer fresh, the cache
     
    10581073      <p id="rfc.section.4.2.p.5"> </p>
    10591074      <ul>
    1060          <li>A <a href="p4-conditional.html#status.304" class="smpl">304 (Not Modified)</a> response status code indicates that the stored response can be updated and reused; see <a href="#freshening.responses" title="Freshening Responses with 304 Not Modified">Section&nbsp;4.2.1</a>.
     1075         <li>A <a href="p4-conditional.html#status.304" class="smpl">304 (Not Modified)</a> response status code indicates that the stored response can be updated and reused; see <a href="#freshening.responses" title="Freshening Stored Responses upon Validation">Section&nbsp;4.2.1</a>.
    10611076         </li>
    10621077         <li>A full response (i.e., one with a payload body) indicates that none of the stored responses nominated in the conditional request
     
    10671082         </li>
    10681083      </ul>
    1069       <h3 id="rfc.section.4.2.1"><a href="#rfc.section.4.2.1">4.2.1</a>&nbsp;<a id="freshening.responses" href="#freshening.responses">Freshening Responses with 304 Not Modified</a></h3>
     1084      <h3 id="rfc.section.4.2.1"><a href="#rfc.section.4.2.1">4.2.1</a>&nbsp;<a id="freshening.responses" href="#freshening.responses">Freshening Stored Responses upon Validation</a></h3>
    10701085      <p id="rfc.section.4.2.1.p.1">When a cache receives a <a href="p4-conditional.html#status.304" class="smpl">304 (Not Modified)</a> response and already has one or more stored <a href="p2-semantics.html#status.200" class="smpl">200 (OK)</a> responses for the same cache key, the cache needs to identify which of the stored responses are updated by this new response
    10711086         and then update the stored response(s) with the new information provided in the <a href="p4-conditional.html#status.304" class="smpl">304</a> response.
     
    10881103      </p>
    10891104      <ul>
    1090          <li>delete any <a href="#header.warning" class="smpl">Warning</a> header fields in the stored response with warn-code 1xx (see <a href="#header.warning" id="rfc.xref.header.warning.2" title="Warning">Section&nbsp;7.5</a>);
     1105         <li>delete any <a href="#header.warning" class="smpl">Warning</a> header fields in the stored response with warn-code 1xx (see <a href="#header.warning" id="rfc.xref.header.warning.3" title="Warning">Section&nbsp;7.5</a>);
    10911106         </li>
    10921107         <li>retain any <a href="#header.warning" class="smpl">Warning</a> header fields in the stored response with warn-code 2xx; and,
     
    11221137         server in a (possibly conditional; see <a href="#validation.model" title="Validation">Section&nbsp;4.2</a>) request.
    11231138      </p>
    1124       <h2 id="rfc.section.4.4"><a href="#rfc.section.4.4">4.4</a>&nbsp;<a id="combining.responses" href="#combining.responses">Combining Partial Content</a></h2>
    1125       <p id="rfc.section.4.4.p.1">A response might transfer only a partial representation if the connection closed prematurely or if the request used one or
    1126          more Range specifiers (<a href="#Part5" id="rfc.xref.Part5.2"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Range Requests">[Part5]</cite></a>). After several such transfers, a cache might have received several ranges of the same representation. A cache <em class="bcp14">MAY</em> combine these ranges into a single stored response, and reuse that response to satisfy later requests, if they all share the
    1127          same strong validator and the cache complies with the client requirements in <a href="p5-range.html#combining.byte.ranges" title="Combining Ranges">Section 4.3</a> of <a href="#Part5" id="rfc.xref.Part5.3"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Range Requests">[Part5]</cite></a>.
    1128       </p>
    1129       <p id="rfc.section.4.4.p.2">When combining the new response with one or more stored responses, a cache <em class="bcp14">MUST</em>:
    1130       </p>
    1131       <ul>
    1132          <li>delete any <a href="#header.warning" class="smpl">Warning</a> header fields in the stored response with warn-code 1xx (see <a href="#header.warning" id="rfc.xref.header.warning.3" title="Warning">Section&nbsp;7.5</a>);
    1133          </li>
    1134          <li>retain any <a href="#header.warning" class="smpl">Warning</a> header fields in the stored response with warn-code 2xx; and,
    1135          </li>
    1136          <li>use other header fields provided in the new response, aside from <a href="p5-range.html#header.content-range" class="smpl">Content-Range</a>, to replace all instances of the corresponding header fields in the stored response.
    1137          </li>
    1138       </ul>
    11391139      <h1 id="rfc.section.5"><a href="#rfc.section.5">5.</a>&nbsp;<a id="head.effects" href="#head.effects">Updating Caches with HEAD Responses</a></h1>
    11401140      <p id="rfc.section.5.p.1">A response to the HEAD method is identical to what an equivalent request made with a GET would have been, except it lacks
     
    21692169                     </ul>
    21702170                  </li>
    2171                   <li><em>Part5</em>&nbsp;&nbsp;<a href="#rfc.xref.Part5.1">3.1</a>, <a href="#rfc.xref.Part5.2">4.4</a>, <a href="#rfc.xref.Part5.3">4.4</a>, <a href="#Part5"><b>12.1</b></a><ul>
    2172                         <li><em>Section 4.3</em>&nbsp;&nbsp;<a href="#rfc.xref.Part5.3">4.4</a></li>
     2171                  <li><em>Part5</em>&nbsp;&nbsp;<a href="#rfc.xref.Part5.1">3.1</a>, <a href="#rfc.xref.Part5.2">3.3</a>, <a href="#rfc.xref.Part5.3">3.3</a>, <a href="#Part5"><b>12.1</b></a><ul>
     2172                        <li><em>Section 4.3</em>&nbsp;&nbsp;<a href="#rfc.xref.Part5.3">3.3</a></li>
    21732173                     </ul>
    21742174                  </li>
     
    22222222            </li>
    22232223            <li><a id="rfc.index.W" href="#rfc.index.W"><b>W</b></a><ul>
    2224                   <li>Warning header field&nbsp;&nbsp;<a href="#rfc.xref.header.warning.1">4.1.4</a>, <a href="#rfc.xref.header.warning.2">4.2.1</a>, <a href="#rfc.xref.header.warning.3">4.4</a>, <a href="#rfc.xref.header.warning.4">5</a>, <a href="#rfc.iref.w.1"><b>7.5</b></a>, <a href="#rfc.xref.header.warning.5">9.3</a>, <a href="#rfc.xref.header.warning.6">A</a>, <a href="#rfc.xref.header.warning.7">A</a></li>
     2224                  <li>Warning header field&nbsp;&nbsp;<a href="#rfc.xref.header.warning.1">3.3</a>, <a href="#rfc.xref.header.warning.2">4.1.4</a>, <a href="#rfc.xref.header.warning.3">4.2.1</a>, <a href="#rfc.xref.header.warning.4">5</a>, <a href="#rfc.iref.w.1"><b>7.5</b></a>, <a href="#rfc.xref.header.warning.5">9.3</a>, <a href="#rfc.xref.header.warning.6">A</a>, <a href="#rfc.xref.header.warning.7">A</a></li>
    22252225               </ul>
    22262226            </li>
  • draft-ietf-httpbis/latest/p6-cache.xml

    r2237 r2238  
    465465</t>
    466466</section>
     467
     468<section anchor="combining.responses" title="Combining Partial Content">
     469<t>
     470   A response might transfer only a partial representation if the
     471   connection closed prematurely or if the request used one or more Range
     472   specifiers (&partial;).  After several such transfers, a cache might have
     473   received several ranges of the same representation.  A cache &MAY; combine
     474   these ranges into a single stored response, and reuse that response to
     475   satisfy later requests, if they all share the same strong validator and
     476   the cache complies with the client requirements in &combining-byte-ranges;.
     477</t>
     478<t>
     479   When combining the new response with one or more stored responses, a
     480   cache &MUST;:
     481   <list style="symbols">
     482      <t>delete any <x:ref>Warning</x:ref> header fields in the stored response
     483         with warn-code 1xx (see <xref target="header.warning" />);</t>
     484      <t>retain any <x:ref>Warning</x:ref> header fields in the stored response
     485         with warn-code 2xx; and,</t>
     486      <t>use other header fields provided in the new response, aside
     487         from <x:ref>Content-Range</x:ref>, to replace all instances of the
     488         corresponding header fields in the stored response.</t>
     489   </list>
     490</t>
     491</section>
     492
    467493</section>
    468494
     
    875901</t>
    876902
    877 <section anchor="freshening.responses" title="Freshening Responses with 304 Not Modified">
     903<section anchor="freshening.responses" title="Freshening Stored Responses upon Validation">
    878904<t>
    879905   When a cache receives a <x:ref>304 (Not Modified)</x:ref> response and
     
    9811007</section>
    9821008
    983 
    984 <section anchor="combining.responses" title="Combining Partial Content">
    985 <t>
    986    A response might transfer only a partial representation if the
    987    connection closed prematurely or if the request used one or more Range
    988    specifiers (&partial;).  After several such transfers, a cache might have
    989    received several ranges of the same representation.  A cache &MAY; combine
    990    these ranges into a single stored response, and reuse that response to
    991    satisfy later requests, if they all share the same strong validator and
    992    the cache complies with the client requirements in &combining-byte-ranges;.
    993 </t>
    994 <t>
    995    When combining the new response with one or more stored responses, a
    996    cache &MUST;:
    997    <list style="symbols">
    998       <t>delete any <x:ref>Warning</x:ref> header fields in the stored response
    999          with warn-code 1xx (see <xref target="header.warning" />);</t>
    1000       <t>retain any <x:ref>Warning</x:ref> header fields in the stored response
    1001          with warn-code 2xx; and,</t>
    1002       <t>use other header fields provided in the new response, aside
    1003          from <x:ref>Content-Range</x:ref>, to replace all instances of the
    1004          corresponding header fields in the stored response.</t>
    1005    </list>
    1006 </t>
    1007 </section>
    10081009</section>
    10091010
Note: See TracChangeset for help on using the changeset viewer.