diff --git a/draft-ietf-httpbis-early-hints.md b/draft-ietf-httpbis-early-hints.md index 8ef798318..a263a28f1 100644 --- a/draft-ietf-httpbis-early-hints.md +++ b/draft-ietf-httpbis-early-hints.md @@ -105,6 +105,9 @@ Aside from performance optimizations, such evaluation of the 103 client MUST NOT interpret the 103 (Early Hints) response header fields as if they applied to the informational response itself (e.g., as metadata about the 103 (Early Hints) response). +A server MAY use a 103 (Early Hints) response to indicate only some of the header fields that are expected to be found in the final response. +A client SHOULD NOT interpret the nonexistence of a header field in a 103 (Early Hints) response as a speculation that the header field is unlikely to be part of the final response. + The following example illustrates a typical message exchange that involves a 103 (Early Hints) response. Client request: @@ -139,6 +142,35 @@ This can happen for example when a caching intermediary generates a 103 (Early H on the header fields of a stale-cached response, then forwards a 103 (Early Hints) response and a final response that were sent from the origin server in response to a revalidation request. +A server MAY emit multiple 103 (Early Hints) responses with additional header fields as new information becomes available while the request is being processed. +It does not need to repeat the fields that were already emitted, though it doesn't have to exclude them either. +The client can consider any combination of header fields received in multiple 103 (Early Hints) responses when anticipating the list of header fields expected in the final response. + +The following example illustrates a series of responses that a server might emit. +In the example, the server uses two 103 (Early Hints) responses to notify the client that it is likely to send three Link header fields in the final response. +Two of the three expected header fields are found in the final response. +The other header field is replaced by another Link header field that contains a different value. + +~~~ example + HTTP/1.1 103 Early Hints + Link: ; rel=preload; as=style + + HTTP/1.1 103 Early Hints + Link: ; rel=preload; as=style + Link: ; rel=preload; as=script + + HTTP/1.1 200 OK + Date: Fri, 26 May 2017 10:02:11 GMT + Content-Length: 1234 + Content-Type: text/html; charset=utf-8 + Link: ; rel=preload; as=style + Link: ; rel=preload; as=style + Link: ; rel=preload; as=script + + + [... rest of the response body is omitted from the example ...] +~~~ + # Security Considerations Some clients might have issues handling 103 (Early Hints), since informational responses are rarely