[html5] r4081 - [] (0) EventSource: Elaborate on when a reconnect should happen in the face of a [...]
whatwg at whatwg.org
whatwg at whatwg.org
Mon Oct 5 03:17:42 PDT 2009
Author: ianh
Date: 2009-10-05 03:17:42 -0700 (Mon, 05 Oct 2009)
New Revision: 4081
Modified:
source
Log:
[] (0) EventSource: Elaborate on when a reconnect should happen in the face of a connection error, and other minor corrections.
Modified: source
===================================================================
--- source 2009-10-05 09:13:05 UTC (rev 4080)
+++ source 2009-10-05 10:17:42 UTC (rev 4081)
@@ -72934,7 +72934,8 @@
<p>The <dfn title="dom-EventSource-URL"><code>URL</code></dfn>
attribute must return the <span>absolute URL</span> that resulted
from <span title="resolve a url">resolving</span> the value that was
- passed to the constructor.</p>
+ passed to the constructor.</p> <!-- not the result of redirects,
+ since that would introduce race conditions -->
<p>The <dfn
title="dom-EventSource-readyState"><code>readyState</code></dfn>
@@ -72968,9 +72969,9 @@
rules given below for handling the connection define when the value
changes.</p>
- <p>The <dfn
- title="dom-EventSource-close"><code>close()</code></dfn>
- method must close the connection, if any, and must set the <code
+ <p>The <dfn title="dom-EventSource-close"><code>close()</code></dfn>
+ method must close the connection, if any; must abort any
+ reconnection attempt, if any; and must set the <code
title="dom-EventSource-readyState">readyState</code> attribute to
<code title="dom-EventSource-CLOSED">CLOSED</code>. If the
connection is already closed, the method must do nothing.</p>
@@ -73056,9 +73057,10 @@
the stream, the user agent must <span>announce the
connection</span>.</p>
- <p>If such a resource (with the correct <span>MIME type</span>) completes loading
- (i.e. the entire HTTP response body is received or the connection
- itself closes), the user agent must <span>reset the
+ <p>If such a resource (with the correct <span>MIME type</span>)
+ completes loading (i.e. either the entire HTTP response body is
+ received, or the connection is closed somehow, whether by the server
+ or by a network error), the user agent must <span>reset the
connection</span>. This doesn't apply for the error cases that are
listed below.</p>
@@ -73097,17 +73099,19 @@
Authentication Required should be treated transparently as for any
other subresource.</p>
- <p>Any other HTTP response code not listed here or network error
- (e.g. DNS errors) must cause the user agent to <span>fail the
- connection</span>.</p> <!-- including: HTTP 300 Multiple Choices,
- HTTP 304 Not Modified, HTTP 400 Bad Request, 403 Forbidden, 404 Not
- Found, 405 Method Not Allowed, 406 Not Acceptable, 408 Request
- Timeout, 409 Conflict, 410 Gone, 411 Length Required, 412
- Precondition Failed, 413 Request Entity Too Large, 414 Request-URI
- Too Long, 415 Unsupported Media Type, 416 Requested Range Not
- Satisfiable, 417 Expectation Failed, 500 Internal Server Error, 501
- Not Implemented, 502 Bad Gateway, 503 Service Unavailable, 504
- Gateway Timeout, and 505 HTTP Version Not Supported responses -->
+ <p>Any other HTTP response code not listed here, and any network
+ error that prevents the HTTP connection from being established in
+ the first place (e.g. DNS errors), must cause the user agent to
+ <span>fail the connection</span>.</p> <!-- including: HTTP 300
+ Multiple Choices, HTTP 304 Not Modified, HTTP 400 Bad Request, 403
+ Forbidden, 404 Not Found, 405 Method Not Allowed, 406 Not
+ Acceptable, 408 Request Timeout, 409 Conflict, 410 Gone, 411 Length
+ Required, 412 Precondition Failed, 413 Request Entity Too Large, 414
+ Request-URI Too Long, 415 Unsupported Media Type, 416 Requested
+ Range Not Satisfiable, 417 Expectation Failed, 500 Internal Server
+ Error, 501 Not Implemented, 502 Bad Gateway, 503 Service
+ Unavailable, 504 Gateway Timeout, and 505 HTTP Version Not Supported
+ responses -->
<p>For non-HTTP protocols, UAs should act in equivalent ways.</p>
@@ -73335,9 +73339,9 @@
name</var> buffer to the empty string and abort these
steps.</p></li>
- <li>If the <var title="">data</var> buffer's last character is a
+ <li><p>If the <var title="">data</var> buffer's last character is a
U+000A LINE FEED (LF) character, then remove the last character
- from the <var title="">data</var> buffer.</p>
+ from the <var title="">data</var> buffer.</p></li>
<li><p>If the <var title="">event name</var> buffer is not the
empty string but is also not a valid event type name, as defined by
More information about the Commit-Watchers
mailing list