[html5] r1598 - /
whatwg at whatwg.org
whatwg at whatwg.org
Mon May 12 18:41:19 PDT 2008
Author: ianh
Date: 2008-05-12 18:41:18 -0700 (Mon, 12 May 2008)
New Revision: 1598
Modified:
index
source
Log:
[w] (2) Application caches: Define what happens when the user cancels the download. Resolve the infinite loop when the server is broken but a fallback resource doesn't have a valid manifest= attribute.
Modified: index
===================================================================
--- index 2008-05-13 01:17:16 UTC (rev 1597)
+++ index 2008-05-13 01:41:18 UTC (rev 1598)
@@ -30519,11 +30519,11 @@
cache</a>, then:
<p>Fetch the resource normally. If this results 4xx or 5xx status codes
- or equivalent, or if there were network errors, then instead fetch, from
- the cache, the resource of the <a href="#fallback0"
- title=concept-appcache-fallback>fallback entry</a> corresponding to the
- namespace with the longest matching <path> component. Abort these
- steps.</p>
+ or equivalent, or if there were network errors (but not if the user
+ canceled the download), then instead fetch, from the cache, the resource
+ of the <a href="#fallback0" title=concept-appcache-fallback>fallback
+ entry</a> corresponding to the namespace with the longest matching
+ <path> component. Abort these steps.</p>
<li>
<p>Fail the resource load.
@@ -30721,7 +30721,8 @@
<li>
<p>If this results 4xx or 5xx status codes or equivalent, or if there
- were network errors, then abort these steps.
+ were network errors, or if the user canceled the download, then abort
+ these steps.
<li>
<p>Wait for there to be no running scripts, or at least no running
@@ -31446,7 +31447,7 @@
title=concept-appcache-manifest>manifest</a> with the same <a
href="#origin0">origin</a> as the URI in question, and that have this
URI as one of their entries (excluding entries marked as <a
- href="#foreign" title=concept-appcache-foreign>manifest</a>), and that
+ href="#foreign" title=concept-appcache-foreign>foreign</a>), and that
already contain their manifest, categorised as a <a href="#the-manifest"
title=concept-appcache-manifest>manifest</a>. If so, then the user agent
must then fetch the resource from the <a href="#select0"
@@ -31482,32 +31483,46 @@
href="#application0">application cache</a>, and was to be fetched using
HTTP GET or equivalent, and its URI <a href="#matches"
title=concept-appcache-matches-oppcache>matches the opportunistic
- caching namespace</a> of one or more application caches, then:</p>
+ caching namespace</a> of one or more application caches, and the user
+ didn't cancel the navigation attempt during the previous step, then:</p>
<dl class=switch>
- <dt>If the file was successfully downloaded
+ <dt>If the browsing context being navigated is a <a
+ href="#top-level">top-level browsing context</a>, and the navigation
+ attempt failed (e.g. the server returned a 4xx or 5xx status code or
+ equivalent, or there was a DNS error)
- <dd>The user agent must cache the resource in all those application
- caches, categorised as <a href="#opportunistically"
- title=concept-appcache-oppcache>opportunistically cached entries</a>.
+ <dd>
+ <p>Let <var title="">candidate</var> be the <a href="#fallback0"
+ title=concept-appcache-fallback>fallback resource</a> specified for
+ the opportunistic caching namespace in question. If multiple
+ application caches match, the user agent must use the fallback of the
+ <a href="#select0" title=concept-appcache-selection>most appropriate
+ application cache</a> of those that match.</p>
- <dt>If the server returned a 4xx or 5xx status code or equivalent, or
- there were network errors
+ <p>If <var title="">candidate</var> is not marked as <a href="#foreign"
+ title=concept-appcache-foreign>foreign</a>, then the user agent must
+ discard the failed load and instead continue along these steps using
+ <var title="">candidate</var> as the resource.</p>
- <dd>If the browsing context being navigated is a <a
- href="#top-level">top-level browsing context</a>, then the user agent
- must discard the failed load and instead use the <a href="#fallback0"
- title=concept-appcache-fallback>fallback resource</a> specified for the
- opportunistic caching namespace in question. If multiple application
- caches match, the user agent must use the fallback of the <a
- href="#select0" title=concept-appcache-selection>most appropriate
- application cache</a> of those that match. For the purposes of session
- history (and features that depend on session history, e.g. bookmarking)
- the user agent must use the URI of the resource that was requested (the
- one that matched the opportunistic caching namespace), not the fallback
- resource. However, the user agent may indicate to the user that the
- original page load failed, that the page used was a fallback resource,
- and what the URI of the fallback resource actually is.
+ <p>For the purposes of session history (and features that depend on
+ session history, e.g. bookmarking) the user agent must use the URI of
+ the resource that was requested (the one that matched the
+ opportunistic caching namespace), not the fallback resource. However,
+ the user agent may indicate to the user that the original page load
+ failed, that the page used was a fallback resource, and what the URI
+ of the fallback resource actually is.</p>
+
+ <dt>Otherwise
+
+ <dd>
+ <p>Once the download is complete, if there were no errors and the user
+ didn't cancel the request, the user agent must cache the resource in
+ all the application caches that have a <a href="#matches"
+ title=concept-appcache-matches-oppcache>matching opportunistic caching
+ namespace</a>, categorised as <a href="#opportunistically"
+ title=concept-appcache-oppcache>opportunistically cached entries</a>.
+ Meanwhile, the user must continue along these steps.</p>
</dl>
<li>
Modified: source
===================================================================
--- source 2008-05-13 01:17:16 UTC (rev 1597)
+++ source 2008-05-13 01:41:18 UTC (rev 1598)
@@ -28390,15 +28390,16 @@
<li>
- <p>If the resource's URI has the same <span>origin</span> as the manifest's URI, and the start of
- the resource's URI's <path> component is exactly matched by
- the <path> component of an <span
- title="concept-appcache-oppcache-ns">opportunistic caching
+ <p>If the resource's URI has the same <span>origin</span> as the
+ manifest's URI, and the start of the resource's URI's <path>
+ component is exactly matched by the <path> component of an
+ <span title="concept-appcache-oppcache-ns">opportunistic caching
namespace</span> in the <span>application cache</span>, then:
<p>Fetch the resource normally. If this results 4xx or 5xx status
- codes or equivalent, or if there were network errors, then instead
- fetch, from the cache, the resource of the <span
+ codes or equivalent, or if there were network errors (but not if
+ the user canceled the download), then instead fetch, from the
+ cache, the resource of the <span
title="concept-appcache-fallback">fallback entry</span>
corresponding to the namespace with the longest matching
<path> component. Abort these steps.</p>
@@ -28584,7 +28585,8 @@
title="">uri</var>.</p></li>
<li><p>If this results 4xx or 5xx status codes or equivalent, or if
- there were network errors, then abort these steps.</p></li>
+ there were network errors, or if the user canceled the download,
+ then abort these steps.</p></li>
<li>
@@ -29289,7 +29291,7 @@
with the same <span>origin</span> as the URI in
question, and that have this URI as one of their entries
(excluding entries marked as <span
- title="concept-appcache-foreign">manifest</span>), and that
+ title="concept-appcache-foreign">foreign</span>), and that
already contain their manifest, categorised as a <span
title="concept-appcache-manifest">manifest</span>. If so, then the
user agent must then fetch the resource from the <span
@@ -29329,38 +29331,58 @@
and its URI <span
title="concept-appcache-matches-oppcache">matches the
opportunistic caching namespace</span> of one or more application
- caches, then:</p>
+ caches, and the user didn't cancel the navigation attempt during
+ the previous step, then:</p>
<dl class="switch">
- <dt>If the file was successfully downloaded</dt>
+ <dt>If the browsing context being navigated is a <span>top-level
+ browsing context</span>, and the navigation attempt failed
+ (e.g. the server returned a 4xx or 5xx status code or equivalent,
+ or there was a DNS error)</dt>
- <dd>The user agent must cache the resource in all those
- application caches, categorised as <span
- title="concept-appcache-oppcache">opportunistically cached
- entries</span>.</dd>
+ <dd>
+ <p>Let <var title="">candidate</var> be the <span
+ title="concept-appcache-fallback">fallback resource</span>
+ specified for the opportunistic caching namespace in
+ question. If multiple application caches match, the user agent
+ must use the fallback of the <span
+ title="concept-appcache-selection">most appropriate application
+ cache</span> of those that match.</p>
- <dt>If the server returned a 4xx or 5xx status code or
- equivalent, or there were network errors</dt>
+ <p>If <var title="">candidate</var> is not marked as <span
+ title="concept-appcache-foreign">foreign</span>, then the user
+ agent must discard the failed load and instead continue along
+ these steps using <var title="">candidate</var> as the
+ resource.</p>
- <dd>If the browsing context being navigated is a <span>top-level
- browsing context</span>, then the user agent must discard the
- failed load and instead use the <span
- title="concept-appcache-fallback">fallback resource</span>
- specified for the opportunistic caching namespace in question. If
- multiple application caches match, the user agent must use the
- fallback of the <span title="concept-appcache-selection">most
- appropriate application cache</span> of those that match. For the
- purposes of session history (and features that depend on session
- history, e.g. bookmarking) the user agent must use the URI of the
- resource that was requested (the one that matched the
- opportunistic caching namespace), not the fallback
- resource. However, the user agent may indicate to the user that
- the original page load failed, that the page used was a fallback
- resource, and what the URI of the fallback resource actually
- is.</dd>
+ <p>For the purposes of session history (and features that depend
+ on session history, e.g. bookmarking) the user agent must use
+ the URI of the resource that was requested (the one that matched
+ the opportunistic caching namespace), not the fallback
+ resource. However, the user agent may indicate to the user that
+ the original page load failed, that the page used was a fallback
+ resource, and what the URI of the fallback resource actually
+ is.</p>
+ </dd>
+
+ <dt>Otherwise</dt>
+
+ <dd>
+
+ <p>Once the download is complete, if there were no errors and
+ the user didn't cancel the request, the user agent must cache
+ the resource in all the application caches that have a <span
+ title="concept-appcache-matches-oppcache">matching opportunistic
+ caching namespace</span>, categorised as <span
+ title="concept-appcache-oppcache">opportunistically cached
+ entries</span>. Meanwhile, the user must continue along these
+ steps.</p>
+
+ </dd>
+
</dl>
</li>
More information about the Commit-Watchers
mailing list