-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add counters that support deployment of L4S #792
Open
alvestrand
wants to merge
7
commits into
main
Choose a base branch
from
l4s-counters
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+159
−2
Open
Changes from 1 commit
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
9ad9362
Add counters that support deployment of L4S
alvestrand a169c52
Create l4s-explainer.md
alvestrand e54f579
Remove internal note
alvestrand 0339554
Minor edits
alvestrand 7c6e500
Fix missing dt
alvestrand dbf5006
Add feedback counts to explainer
alvestrand e820135
Add ccfb counters to webrtc-stats.html
alvestrand File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Loading status checks…
Create l4s-explainer.md
This is the explainer for the counters proposed in the PR.
commit a169c52e9d417e3f42cccb694baad2c88d6510dc
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
<!-- Output copied to clipboard! --> | ||
|
||
|
||
|
||
# Explainer - RFC8888 and L4S stats support in webrtc-stats | ||
|
||
This explainer gives the background for the proposal to add stats to webrtc-stats to support the deployment of L4S and its prerequisite reporting format, RFC8888. | ||
|
||
(Google-only note: see go/webrtc-l4s for details on what L4S is and why it’s important). | ||
|
||
|
||
## What is L4S | ||
|
||
L4S is a strategy for packet scheduling and marking in the Internet that is intended to make the Internet better for latency-sensitive applications that are capable of and willing to rapidly respond to signals that indicate queue buildup. | ||
|
||
The elements constituting L4S, seen from an application, are: | ||
|
||
|
||
|
||
* The data sender marks outgoing packets with the bit pattern ECT(1) (01) (rather than the default, “no signal” (00) | ||
* Network elements, when observing queue buildup, change the ECT(1) bit pattern to the CE (Congestion Experienced) bit pattern (11). | ||
* The data recipient reflects the bits observed on each packet back to the sender, using the RFC8888 reporting format | ||
* The data sender adjusts its send rate according to the observations in the report | ||
|
||
|
||
## What we need to diagnose | ||
|
||
There are a number of scenarios we want to diagnose: | ||
|
||
|
||
|
||
* CE-aware chokepoints: ECT(1) gets sent and received, the occasional CE gets received, and reflected back to the sender, which adjusts bitrate accordingly | ||
* Bleaching: ECT(1) gets sent, but the recipient sees “No signal” | ||
* Network drops: Packets marked with ECT(1) get dropped, packets without it get through | ||
* CE-less chokepoints: We observe packet loss, but no CE markings. | ||
|
||
We may also want to look at packet loss vs packet reordering - when packets are lost, the reports will contain loss markings; when packets are reordered, later reports will overlap the previous reports and add info on packets previously lost. | ||
|
||
|
||
## Suggested counters and where to attach them | ||
|
||
The following counters are proposed: | ||
|
||
Attached to RTCSentRtpStreamStats: | ||
|
||
|
||
|
||
* Number of packets sent with normal markings (this can be calculated from PacketsSent - Ect1PacketsSent, so no explicit counter is needed) | ||
* Number of packets sent with ECT(1) markings | ||
|
||
Attached to RTCReceivedRtpStreamStats: | ||
|
||
|
||
|
||
* Number of packets received with normal markings | ||
* Number of packets received with ECT(1) marking | ||
* Number of packets received with CE marking | ||
* Number of packets reported as lost in RFC8888 reports | ||
* Number of packets reported as lost in one RFC8888 report but later reported as arrived | ||
|
||
Attached to RTCRemoteInboundRtpStreamStats (which is a subclass of RTCReceivedRtpStreamStats): | ||
|
||
|
||
|
||
* Number of packets sent with ECT(1) but reported as “no marking” (Bleached) | ||
|
||
Data in RTCRemoteInboundRtpStreamStats are computed based on a sender’s knowledge of the outgoing packets + data from remote reports (RR or RFC8888 reports). Computing “bleached” packets requires having both info on the sent packet and info on the RFC8888 report available. | ||
|
||
|
||
## How to diagnose scenarios from these numbers | ||
|
||
Diagnosing is performed at the sending endpoint. | ||
|
||
|
||
|
||
* CE-aware chokepoints: ECT(1) is sent, ECT(1) and CE are in reports, reported ECT(1) + CE + lost add up to number of sent packets (modulo in-flight). Bleaching stays at zero. | ||
* Bleaching: ECT(1) is sent, but “no marking” is reported. Number of sent packets and number of received packets + lost are roughly equal. | ||
* Network drops: Packets sent with normal and ECT(1) are both above zero, but packets received are only normal, not ECT(1), and correspond to the number of normal packets. (NOTE: This is a failure scenario for deploying L4S) | ||
* CE-less chokepoints: ECT(1) is sent and received, but CE counter remains at zero. | ||
|
||
If excessive reordering occurs, the “reported later” counters will go up; the precise interpretation of that number depends on the strategy used for scheduling RFC8888 reports (longer intervals will allow more reordered packets to be recovered without this being visible in the reports). |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another counter useful would be RFC 8888 feedback send interval. Cumulative RFC 8888 feedback sent and Cumulative RFC feedback interval. Avg interval could be computed using those 2 stats.