RFC 9209 specifically calls out some use cases for Proxy-Status as a trailer. draft-ietf-connect-tcp says
In HTTP/2 or HTTP/3, proxies MAY additionally send a "Proxy-Status" trailer in the event of an abrupt stream closure.
However, RFC 9113 (HTTP/2) says
Frame types other than DATA or stream management frames (RST_STREAM, WINDOW_UPDATE, and PRIORITY) MUST NOT be sent on a connected stream and MUST be treated as a stream error (Section 5.4.2) if received.
and RFC 9114 (HTTP/3) says
Once the CONNECT method has completed, only DATA frames are permitted to be sent on the stream. Extension frames MAY be used if specifically permitted by the definition of the extension. Receipt of any other known frame type MUST be treated as a connection error of type H3_FRAME_UNEXPECTED.
Possible ways forward:
- Drop this text from connect-tcp.
- This leaves no way to convey details of why a connection closed uncleanly (e.g. "this proxy instance is shutting down" vs. "connection timeout" vs. "you have exceeded your monthly transfer quota") for debugging.
- Define a new Capsule to convey shutdown metadata (generally) or Proxy-Status (specifically).
- Allows HTTP/1.1 support
- Creates redundancy with trailers and/or Proxy-Status in HTTP/2 and HTTP/3. Adds some complexity when chaining proxies.
- Interpret ":protocol" values as "extensions" for the purpose of HTTP/3 ("Extension frames MAY be used if specifically permitted by the definition of the extension"), and assume a similar extensibility rule in HTTP/2. Add text noting that "connect-tcp" permits trailers.
- Allow trailers in all Capsule-Protocol or all Extended-CONNECT responses.
- Theoretically constitutes a non-backward-compatible change to published RFCs. (Unclear if this would have any practical consequence.)
- Probably requires a separate draft.
See also the mailing list thread.
RFC 9209 specifically calls out some use cases for Proxy-Status as a trailer. draft-ietf-connect-tcp says
However, RFC 9113 (HTTP/2) says
and RFC 9114 (HTTP/3) says
Possible ways forward:
See also the mailing list thread.