Use RTX channel for bandwidth probing (#3250)

This commit is contained in:
Raja Subramanian
2024-12-14 11:51:58 +05:30
committed by GitHub
parent 6df339b77c
commit 8cfea87ad0
7 changed files with 466 additions and 192 deletions
+17 -13
View File
@@ -68,8 +68,8 @@ type ProbeSignalConfig struct {
JQRMinDelay time.Duration `yaml:"jqr_min_delay,omitempty"`
DQRMaxDelay time.Duration `yaml:"dqr_max_delay,omitempty"`
WeightedLoss WeightedLossConfig `yaml:"weighted_loss,omitempty"`
CongestionMinLoss float64 `yaml:"congestion_min_loss,omitempty"`
WeightedLoss WeightedLossConfig `yaml:"weighted_loss,omitempty"`
CongestionMinWeightedLoss float64 `yaml:"congestion_min_weighted_loss,omitempty"`
}
func (p ProbeSignalConfig) IsValid(pci ccutils.ProbeClusterInfo) bool {
@@ -87,7 +87,7 @@ func (p ProbeSignalConfig) ProbeSignal(ppg *probePacketGroup) (ccutils.ProbeSign
return ccutils.ProbeSignalCongesting, ts.AcknowledgedBitrate()
}
if ts.WeightedLoss() > p.CongestionMinLoss {
if ts.WeightedLoss() > p.CongestionMinWeightedLoss {
return ccutils.ProbeSignalCongesting, ts.AcknowledgedBitrate()
}
@@ -106,8 +106,8 @@ var (
JQRMinDelay: 15 * time.Millisecond,
DQRMaxDelay: 5 * time.Millisecond,
WeightedLoss: defaultWeightedLossConfig,
CongestionMinLoss: 0.25,
WeightedLoss: defaultWeightedLossConfig,
CongestionMinWeightedLoss: 0.25,
}
)
@@ -335,8 +335,8 @@ type CongestionDetectorConfig struct {
JQRMinDelay time.Duration `yaml:"jqr_min_delay,omitempty"`
DQRMaxDelay time.Duration `yaml:"dqr_max_delay,omitempty"`
WeightedLoss WeightedLossConfig `yaml:"weighted_loss,omitempty"`
CongestionMinLoss float64 `yaml:"congestion_min_loss,omitempty"`
WeightedLoss WeightedLossConfig `yaml:"weighted_loss,omitempty"`
CongestionMinWeightedLoss float64 `yaml:"congestion_min_weighted_loss,omitempty"`
QueuingDelayEarlyWarning CongestionSignalConfig `yaml:"queuing_delay_early_warning,omitempty"`
LossEarlyWarning CongestionSignalConfig `yaml:"loss_early_warning,omitempty"`
@@ -377,8 +377,8 @@ var (
JQRMinDelay: 15 * time.Millisecond,
DQRMaxDelay: 5 * time.Millisecond,
WeightedLoss: defaultWeightedLossConfig,
CongestionMinLoss: 0.25,
WeightedLoss: defaultWeightedLossConfig,
CongestionMinWeightedLoss: 0.25,
QueuingDelayEarlyWarning: defaultQueuingDelayEarlyWarningCongestionSignalConfig,
LossEarlyWarning: defaultLossEarlyWarningCongestionSignalConfig,
@@ -731,7 +731,7 @@ func (c *congestionDetector) isCongestionSignalTriggered() (bool, string, bool,
c.params.Config.LossEarlyWarning,
c.params.Config.LossCongested,
c.params.Config.WeightedLoss,
c.params.Config.CongestionMinLoss,
c.params.Config.CongestionMinWeightedLoss,
c.params.Logger,
)
@@ -760,11 +760,13 @@ func (c *congestionDetector) isCongestionSignalTriggered() (bool, string, bool,
if earlyWarningTriggered {
earlyWarningReason = "queuing-delay"
oldestContributingGroup = qdMeasurement.EarlyWarningGroupIdx()
c.params.Logger.Debugw("send side bwe: early warning queuing-delay", "qd", qdMeasurement)
} else {
earlyWarningTriggered = lossMeasurement.IsEarlyWarningTriggered()
if earlyWarningTriggered {
earlyWarningReason = "loss"
oldestContributingGroup = lossMeasurement.EarlyWarningGroupIdx()
c.params.Logger.Debugw("send side bwe: early warning loss", "loss", lossMeasurement)
}
}
@@ -773,11 +775,13 @@ func (c *congestionDetector) isCongestionSignalTriggered() (bool, string, bool,
if congestedTriggered {
congestedReason = "queuing-delay"
oldestContributingGroup = qdMeasurement.CongestedGroupIdx()
c.params.Logger.Debugw("send side bwe: congested queuing-delay", "qd", qdMeasurement)
} else {
congestedTriggered = lossMeasurement.IsCongestedTriggered()
if congestedTriggered {
congestedReason = "loss"
oldestContributingGroup = lossMeasurement.CongestedGroupIdx()
c.params.Logger.Debugw("send side bwe: congested loss", "loss", lossMeasurement)
}
}
@@ -793,7 +797,7 @@ func (c *congestionDetector) congestionDetectionStateMachine() (bool, bwe.Conges
switch state {
case bwe.CongestionStateNone:
if congestedTriggered {
if congestedTriggered && !earlyWarningTriggered {
c.params.Logger.Warnw("send side bwe: invalid congested state transition", nil, "from", state, "reason", congestedReason)
}
if earlyWarningTriggered {
@@ -810,7 +814,7 @@ func (c *congestionDetector) congestionDetectionStateMachine() (bool, bwe.Conges
}
case bwe.CongestionStateEarlyWarningHangover:
if congestedTriggered {
if congestedTriggered && !earlyWarningTriggered {
c.params.Logger.Warnw("send side bwe: invalid congested state transition", nil, "from", state, "reason", congestedReason)
}
if earlyWarningTriggered {
@@ -826,7 +830,7 @@ func (c *congestionDetector) congestionDetectionStateMachine() (bool, bwe.Conges
}
case bwe.CongestionStateCongestedHangover:
if congestedTriggered {
if congestedTriggered && !earlyWarningTriggered {
c.params.Logger.Warnw("send side bwe: invalid congested state transition", nil, "from", state, "reason", congestedReason)
}
if earlyWarningTriggered {
+1 -1
View File
@@ -112,7 +112,7 @@ func (p *packetTracker) RecordPacketIndicationFromRemote(sn uint16, recvTime int
}
if recvTime == 0 {
// maybe lost OR already receied but reported lost in a later report
// maybe lost OR already received but reported lost in a later report
piRecv = *pi
return
}