config: reject unknown send_side_bwe_pacer, warn on unwired fallback (#4804)
send_side_bwe_pacer accepted any string and silently ran no-queue. leaky-bucket is a defined PacerBehavior with a full LeakyBucket implementation, but the selection switch in NewPCTransport only handled pass-through and no-queue, so both leaky-bucket and outright typos fell through to the default with no diagnostic. leaky-bucket is deliberately left unwired here. LeakyBucket paces to a bitrate supplied via Pacer.SetBitrate, and no production code calls SetBitrate or SetInterval -- Base no-ops both and the only caller in the tree is the test-only capturingPacer. Wiring it as-is would pace at a static bitrate and ignore the bandwidth estimate, which is worse than the fallback. Instead, make the existing behaviour visible: CongestionControlConfig.Validate rejects unrecognised values at startup, the fallback logs a warning naming the requested pacer, and config-sample.yaml documents send_side_bwe_pacer and use_send_side_bwe for the first time. Refs #4724 Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
ad54223d1b
commit
aa08becc6a
@@ -117,6 +117,16 @@ rtc:
|
||||
# # in the unlikely event of highly congested networks, SFU may choose to pause some tracks
|
||||
# # in order to allow others to stream smoothly. You can disable this behavior here
|
||||
# allow_pause: true
|
||||
# # use send-side bandwidth estimation instead of relying on receiver reports, default false
|
||||
# use_send_side_bwe: false
|
||||
# # how egress is paced when use_send_side_bwe is enabled. one of:
|
||||
# # no-queue - hand packets to a send worker that drains them without rate
|
||||
# # limiting, so the sender never blocks on a write (default)
|
||||
# # pass-through - send each packet inline on the calling goroutine
|
||||
# # leaky-bucket - accepted, but not currently wired to the bandwidth estimate; it
|
||||
# # logs a warning and falls back to no-queue. see livekit/livekit#4724
|
||||
# # an unrecognized value is rejected at startup.
|
||||
# send_side_bwe_pacer: no-queue
|
||||
# # allows automatic connection fallback to TCP and TURN/TLS (if configured) when UDP has been unstable, default true
|
||||
# allow_tcp_fallback: true
|
||||
# # signaling RTT (in milliseconds) below which ICE/TCP is attempted on a UDP failure; at or above it,
|
||||
|
||||
Reference in New Issue
Block a user