More detailed logging to understand old packets. (#2730)

This commit is contained in:
Raja Subramanian
2024-05-25 18:34:55 +05:30
committed by GitHub
parent cf8c462805
commit 8be2005e0f
4 changed files with 177 additions and 5 deletions
+8 -1
View File
@@ -570,7 +570,14 @@ func (b *Buffer) calc(rawPkt []byte, rtpPacket *rtp.Packet, arrivalTime time.Tim
if errors.Is(err, bucket.ErrPacketTooOld) {
packetTooOldCount := b.packetTooOldCount.Inc()
if (packetTooOldCount-1)%100 == 0 {
b.logger.Warnw("could not add packet to bucket", err, "count", packetTooOldCount)
b.logger.Warnw(
"could not add packet to bucket", err,
"count", packetTooOldCount,
"flowState", &flowState,
"snAdjustment", snAdjustment,
"incomingSequenceNumber", flowState.ExtSequenceNumber+snAdjustment,
"rtpStats", b.rtpStats,
)
}
} else if err != bucket.ErrRTXPacket {
b.logger.Warnw("could not add packet to bucket", err)