Demote some less useful/noisy logs. (#2743)

This commit is contained in:
Raja Subramanian
2024-05-29 12:05:18 +05:30
committed by GitHub
parent 447793d077
commit f9f761b223
5 changed files with 28 additions and 17 deletions
+1 -3
View File
@@ -314,9 +314,7 @@ func (p *ParticipantImpl) writeMessage(msg *livekit.SignalResponse) error {
func (p *ParticipantImpl) CloseSignalConnection(reason types.SignallingCloseReason) { func (p *ParticipantImpl) CloseSignalConnection(reason types.SignallingCloseReason) {
sink := p.getResponseSink() sink := p.getResponseSink()
if sink != nil { if sink != nil {
if reason != types.SignallingCloseReasonParticipantClose { p.params.Logger.Debugw("closing signal connection", "reason", reason, "connID", sink.ConnectionID())
p.params.Logger.Infow("closing signal connection", "reason", reason, "connID", sink.ConnectionID())
}
sink.Close() sink.Close()
p.SetResponseSink(nil) p.SetResponseSink(nil)
} }
+1 -1
View File
@@ -440,7 +440,7 @@ func (q *qualityScorer) updateAtLocked(stat *windowStat, at time.Time) {
prevCQ := scoreToConnectionQuality(q.score) prevCQ := scoreToConnectionQuality(q.score)
currCQ := scoreToConnectionQuality(score) currCQ := scoreToConnectionQuality(score)
if utils.IsConnectionQualityLower(prevCQ, currCQ) { if utils.IsConnectionQualityLower(prevCQ, currCQ) {
q.params.Logger.Infow( q.params.Logger.Debugw(
"quality drop", "quality drop",
"reason", reason, "reason", reason,
"prevScore", q.score, "prevScore", q.score,
+2 -2
View File
@@ -99,12 +99,12 @@ func (p *ProbeController) CheckProbe(trend ChannelTrend, highestEstimate int64)
// In rare cases, the estimate gets stuck. Prevent from probe running amok // In rare cases, the estimate gets stuck. Prevent from probe running amok
// STREAM-ALLOCATOR-TODO: Need more testing here to ensure that probe does not cause a lot of damage // STREAM-ALLOCATOR-TODO: Need more testing here to ensure that probe does not cause a lot of damage
// //
p.params.Logger.Infow("stream allocator: probe: aborting, no trend", "cluster", p.probeClusterId) p.params.Logger.Debugw("stream allocator: probe: aborting, no trend", "cluster", p.probeClusterId)
p.abortProbeLocked() p.abortProbeLocked()
case trend == ChannelTrendCongesting: case trend == ChannelTrendCongesting:
// stop immediately if the probe is congesting channel more // stop immediately if the probe is congesting channel more
p.params.Logger.Infow("stream allocator: probe: aborting, channel is congesting", "cluster", p.probeClusterId) p.params.Logger.Debugw("stream allocator: probe: aborting, channel is congesting", "cluster", p.probeClusterId)
p.abortProbeLocked() p.abortProbeLocked()
case highestEstimate > p.probeGoalBps: case highestEstimate > p.probeGoalBps:
+1 -1
View File
@@ -189,7 +189,7 @@ func (p *Prober) Reset() {
p.clustersMu.Lock() p.clustersMu.Lock()
if p.activeCluster != nil { if p.activeCluster != nil {
p.logger.Infow("prober: resetting active cluster", "cluster", p.activeCluster.String()) p.logger.Debugw("prober: resetting active cluster", "cluster", p.activeCluster.String())
reset = true reset = true
info = p.activeCluster.GetInfo() info = p.activeCluster.GetInfo()
} }
+23 -10
View File
@@ -818,16 +818,29 @@ func (s *StreamAllocator) handleNewEstimateInNonProbe() {
action = "skipping" action = "skipping"
} }
s.params.Logger.Infow( if action == "applying" {
fmt.Sprintf("stream allocator: channel congestion detected, %s channel capacity update", action), s.params.Logger.Infow(
"reason", reason, fmt.Sprintf("stream allocator: channel congestion detected, %s channel capacity update", action),
"old(bps)", s.committedChannelCapacity, "reason", reason,
"new(bps)", estimateToCommit, "old(bps)", s.committedChannelCapacity,
"lastReceived(bps)", s.lastReceivedEstimate, "new(bps)", estimateToCommit,
"expectedUsage(bps)", expectedBandwidthUsage, "lastReceived(bps)", s.lastReceivedEstimate,
"commitThreshold(bps)", commitThreshold, "expectedUsage(bps)", expectedBandwidthUsage,
"channel", s.channelObserver.ToString(), "commitThreshold(bps)", commitThreshold,
) "channel", s.channelObserver.ToString(),
)
} else {
s.params.Logger.Debugw(
fmt.Sprintf("stream allocator: channel congestion detected, %s channel capacity update", action),
"reason", reason,
"old(bps)", s.committedChannelCapacity,
"new(bps)", estimateToCommit,
"lastReceived(bps)", s.lastReceivedEstimate,
"expectedUsage(bps)", expectedBandwidthUsage,
"commitThreshold(bps)", commitThreshold,
"channel", s.channelObserver.ToString(),
)
}
/* STREAM-ALLOCATOR-DATA /* STREAM-ALLOCATOR-DATA
s.params.Logger.Debugw( s.params.Logger.Debugw(
fmt.Sprintf("stream allocator: channel congestion detected, %s channel capacity: experimental", action), fmt.Sprintf("stream allocator: channel congestion detected, %s channel capacity: experimental", action),