@@ -439,26 +439,37 @@ push by sending a MAX_PUSH_ID frame (see {{frame-max-push-id}}). A server cannot
439439use server push until it receives a MAX_PUSH_ID frame.
440440
441441As with server push for HTTP/2, the server initiates a server push by sending a
442- PUSH_PROMISE frame that includes request header fields attributed to the
443- request. Promised requests MUST be cacheable (see {{!RFC7231}}, Section 4.2.3),
444- MUST be safe (see {{RFC7231}}, Section 4.2.1), and MUST NOT include a request
445- body.
442+ PUSH_PROMISE frame (see {{frame-push-promise}}) that includes request headers
443+ for the promised request. Promised requests MUST be cacheable (see
444+ {{!RFC7231}}, Section 4.2.3), MUST be safe (see {{RFC7231}}, Section 4.2.1), and
445+ MUST NOT include a request body.
446446
447447The PUSH_PROMISE frame is sent on the client-initiated, bidirectional stream
448448that carried the request that generated the push. This allows the server push
449449to be associated with a request. Ordering of a PUSH_PROMISE in relation to
450450certain parts of the response is important (see Section 8.2.1 of {{!RFC7540}}).
451451
452452Unlike HTTP/2, the PUSH_PROMISE does not reference a stream; it contains a Push
453- ID. The Push ID uniquely identifies a server push (see {{frame-push-promise}}).
454- This allows a server to fulfill promises in the order that best suits its needs.
453+ ID. The Push ID uniquely identifies a server push. This allows a server to
454+ fulfill promises in the order that best suits its needs.
455455
456456When a server later fulfills a promise, the server push response is conveyed on
457457a push stream. A push stream is a server-initiated, unidirectional stream. A
458- push stream always begins with a header (see {{fig-push-stream-header}}) that
459- identifies the Push ID of the promise that it fulfills, encoded as a
458+ push stream identifies the Push ID of the promise that it fulfills, encoded as a
460459variable-length integer.
461460
461+ A server SHOULD use Push IDs sequentially, starting at 0. A client uses the
462+ MAX_PUSH_ID frame ({{frame-max-push-id}}) to limit the number of pushes that a
463+ server can promise. A client MUST treat receipt of a push stream with a Push ID
464+ that is greater than the maximum Push ID as a connection error of type
465+ HTTP_PUSH_LIMIT_EXCEEDED.
466+
467+ If a promised server push is not needed by the client, the client SHOULD send a
468+ CANCEL_PUSH frame; if the push stream is already open, a QUIC STOP_SENDING frame
469+ with an appropriate error code can be used instead (e.g., HTTP_PUSH_REFUSED,
470+ HTTP_PUSH_ALREADY_IN_CACHE; see {{errors}}). This asks the server not to
471+ transfer the data and indicates that it will be discarded upon receipt.
472+
462473~~~~~~~~~~ drawing
463474 0 1 2 3
464475 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
@@ -468,28 +479,16 @@ variable-length integer.
468479~~~~~~~~~~
469480{: # fig-push-stream-header title="Push Stream Header"}
470481
471- A server SHOULD use Push IDs sequentially, starting at 0. A client uses the
472- MAX_PUSH_ID frame ({{frame-max-push-id}}) to limit the number of pushes that a
473- server can promise. A client MUST treat receipt of a push stream with a Push ID
474- that is greater than the maximum Push ID as a connection error of type
475- HTTP_PUSH_LIMIT_EXCEEDED.
476-
477- Each Push ID MUST only be used once in a push stream header. If a push stream
478- header includes a Push ID that was used in another push stream header, the
479- client MUST treat this as a connection error of type HTTP_DUPLICATE_PUSH. The
480- same Push ID can be used in multiple PUSH_PROMISE frames (see
481- {{frame-push-promise}}).
482+ Push streams always begin with a header containing the Push ID. Each Push ID
483+ MUST only be used once in a push stream header. If a push stream header
484+ includes a Push ID that was used in another push stream header, the client MUST
485+ treat this as a connection error of type HTTP_DUPLICATE_PUSH. The same Push ID
486+ can be used in multiple PUSH_PROMISE frames (see {{frame-push-promise}}).
482487
483- After the push stream header, a push contains a response ({{request-response}}),
488+ After the header, a push stream contains a response ({{request-response}}),
484489with response headers, a response body (if any) carried by DATA frames, then
485490trailers (if any) carried by HEADERS frames.
486491
487- If a promised server push is not needed by the client, the client SHOULD send a
488- CANCEL_PUSH frame; if the push stream is already open, a QUIC STOP_SENDING frame
489- with an appropriate error code can be used instead (e.g., HTTP_PUSH_REFUSED,
490- HTTP_PUSH_ALREADY_IN_CACHE; see {{errors}}). This asks the server not to
491- transfer the data and indicates that it will be discarded upon receipt.
492-
493492
494493# HTTP Framing Layer {#http-framing-layer}
495494
0 commit comments