Stringer interface (#3181)

This commit is contained in:
Raja Subramanian
2024-11-16 10:14:37 +05:30
committed by GitHub
parent 6509cdb5ea
commit aa2ce22655
3 changed files with 5 additions and 5 deletions

View File

@@ -154,11 +154,11 @@ func (c *channelObserver) GetTrend() (bwe.ChannelTrend, channelCongestionReason)
switch {
case estimateDirection == ccutils.TrendDirectionDownward:
c.logger.Debugw("stream allocator: channel observer: estimate is trending downward", "channel", c)
c.logger.Debugw("remote bwe: channel observer: estimate is trending downward", "channel", c)
return bwe.ChannelTrendCongesting, channelCongestionReasonEstimate
case c.nackTracker.IsTriggered():
c.logger.Debugw("stream allocator: channel observer: high rate of repeated NACKs", "channel", c)
c.logger.Debugw("remote bwe: channel observer: high rate of repeated NACKs", "channel", c)
return bwe.ChannelTrendCongesting, channelCongestionReasonLoss
case estimateDirection == ccutils.TrendDirectionUpward:

View File

@@ -116,7 +116,7 @@ func (n *nackTracker) IsTriggered() bool {
return false
}
func (n *nackTracker) ToString() string {
func (n *nackTracker) String() string {
window := ""
if !n.windowStartTime.IsZero() {
now := time.Now()
@@ -136,7 +136,7 @@ func (n *nackTracker) updateHistory() {
n.history = n.history[1:]
}
n.history = append(n.history, n.ToString())
n.history = append(n.history, n.String())
}
*/

View File

@@ -263,7 +263,7 @@ func (r *RemoteBWE) ProbingStart(expectedBandwidthUsage int64) {
r.lastExpectedBandwidthUsage = expectedBandwidthUsage
r.params.Logger.Debugw(
"stream allocator: starting probe",
"remote bwe: starting probe",
"lastReceived", r.lastReceivedEstimate,
"expectedBandwidthUsage", expectedBandwidthUsage,
"channel", r.channelObserver,