diff --git a/index.bs b/index.bs index 4084a1d..533461d 100644 --- a/index.bs +++ b/index.bs @@ -131,7 +131,8 @@ session=] can contain multiple [=WebTransport streams=]. ## WebTransport session ## {#webtransport-session} -A WebTransport session is a session of WebTransport over HTTP/3. +A WebTransport session is a session of WebTransport over an HTTP/3 +or HTTP/2 underlying [=connection=]. There may be multiple [=WebTransport sessions=] on one [=connection=], when pooling is enabled. A [=WebTransport session=] has the following capabilities defined in [[!WEB-TRANSPORT-HTTP3]]: @@ -601,7 +602,7 @@ defined in [[!WEB-TRANSPORT-HTTP3]]. interface WebTransport { constructor(USVString url, optional WebTransportOptions options = {}); - Promise<WebTransportStats> getStats(); + Promise<WebTransportConnectionStats> getStats(); readonly attribute Promise<undefined> ready; readonly attribute WebTransportReliabilityMode reliability; readonly attribute WebTransportCongestionControl congestionControl; @@ -983,10 +984,9 @@ these steps. 1. Let |transport| be [=this=]. 1. Let |p| be a new promise. 1. Run the following steps [=in parallel=]: - 1. Gather the stats from the underlying QUIC connection, including stats on datagrams. - 1. Wait for the stats to be ready. + 1. Gather the stats from the [=underlying connection=], including stats on datagrams. 1. [=Queue a network task=] with |transport| to run the following steps: - 1. Let |stats| be a [=new=] {{WebTransportStats}} object representing the gathered stats. + 1. Let |stats| be a [=new=] {{WebTransportConnectionStats}} object representing the gathered stats. 1. [=Resolve=] |p| with |stats|. 1. Return |p|. @@ -1134,7 +1134,7 @@ Whenever a [=WebTransport session=] which is associated with a {{WebTransport}}
-dictionary WebTransportStats { +dictionary WebTransportConnectionStats { DOMHighResTimeStamp timestamp; unsigned long long bytesSent; unsigned long long packetsSent; @@ -1345,35 +1345,35 @@ dictionary WebTransportStats { The dictionary SHALL have the following attributes: -: timestamp +: timestamp :: The `timestamp` for when the stats are gathered, relative to the UNIX epoch (Jan 1, 1970, UTC). -: bytesSent -:: The number of bytes sent on the QUIC connection, including retransmissions. +: bytesSent +:: The number of bytes sent on the [=underlying connection=], including retransmissions. Does not include UDP or any other outer framing. -: packetsSent -:: The number of packets sent on the QUIC connection, including those that are determined to have been lost. -: bytesLost -:: The number of bytes lost on the QUIC connection (does not monotonically increase, because packets that are declared lost can subsequently be received). +: packetsSent +:: The number of packets sent on the [=underlying connection=], including those that are determined to have been lost. +: bytesLost +:: The number of bytes lost on the [=underlying connection=] (does not monotonically increase, because packets that are declared lost can subsequently be received). Does not include UDP or any other outer framing. -: packetsLost -:: The number of packets lost on the QUIC connection (does not monotonically increase, because packets that are declared lost can subsequently be received). -: bytesReceived -:: The number of total bytes received on the QUIC connection, including +: packetsLost +:: The number of packets lost on the [=underlying connection=] (does not monotonically increase, because packets that are declared lost can subsequently be received). +: bytesReceived +:: The number of total bytes received on the [=underlying connection=], including duplicate data for streams. Does not include UDP or any other outer framing. -: packetsReceived -:: The number of total packets received on the QUIC connection, including +: packetsReceived +:: The number of total packets received on the [=underlying connection=], including packets that were not processable. -: smoothedRtt +: smoothedRtt :: The smoothed round-trip time (RTT) currently observed on the connection, as defined in [[!RFC9002]] [Section 5.3](https://www.rfc-editor.org/rfc/rfc9002#section-5.3). -: rttVariation +: rttVariation :: The mean variation in round-trip time samples currently observed on the connection, as defined in [[!RFC9002]] [Section 5.3](https://www.rfc-editor.org/rfc/rfc9002#section-5.3). -: minRtt +: minRtt :: The minimum round-trip time observed on the entire connection. -: estimatedSendRate +: estimatedSendRate :: The estimated rate at which queued data will be sent by the user agent, in bits per second. This rate applies to all streams and datagrams that share a [=WebTransport session=] and is calculated by the congestion control algorithm (potentially chosen by @@ -1716,7 +1716,6 @@ The {{WebTransportReceiveStream}}'s [=transfer steps=] and 1. Let |p| be a new promise. 1. Run the following steps [=in parallel=]: 1. Gather the stats specific to this {{WebTransportReceiveStream}}. - 1. Wait for the stats to be ready. 1. [=Queue a network task=] with |transport| to run the following steps: 1. Let |stats| be a [=new=] {{WebTransportReceiveStreamStats}} object representing the gathered stats. @@ -2343,7 +2342,7 @@ possible. Information about the network is available to the server either directly through its own networking stack, indirectly through the rate at which data is consumed or transmitted by the client, or as part of the statistics provided by the API -(see [[#web-transport-stats]]). Consequently, restrictions on information in +(see [[#web-transport-connection-stats]]). Consequently, restrictions on information in user agents is not the only mechanism that might be needed to manage these privacy risks. @@ -2378,7 +2377,7 @@ This might allow sites to increase confidence that activity on different sites originates from the same user. A user agent could limit or degrade access to feedback mechanisms such as -statistics ([[#web-transport-stats]]) for sites that are inactive or do not have +statistics ([[#web-transport-connection-stats]]) for sites that are inactive or do not have focus ([[html/interaction#focus]]). As noted, this does not prevent a server from making observations about changes in the network.