Compute delta stats to send downstream (#426)
* Compute delta stats to send downstream Signed-off-by: shishir gowda <shishir@livekit.io> * Update tests: total_packets should be diff between 2 packets First packet was 1, second was 4. diff should be 3 Signed-off-by: shishir gowda <shishir@livekit.io> * If there are no videoLayers, do not sent in Stats For audio and Downstream tracks, we do not get layers Signed-off-by: shishir gowda <shishir@livekit.io> * Use prev Max layer for current delta and update layer info for next round
This commit is contained in:
@@ -226,7 +226,7 @@ func Test_PacketLostDiffShouldBeSentToTelemetry(t *testing.T) {
|
||||
_, stats = fixture.analytics.SendStatsArgsForCall(1)
|
||||
require.Equal(t, 1, len(stats))
|
||||
require.Equal(t, livekit.StreamType_DOWNSTREAM, stats[0].Kind)
|
||||
require.Equal(t, 4, int(stats[0].Streams[0].TotalPacketsLost)) // see diff of TotalLost between pkts2 and pkts1
|
||||
require.Equal(t, 3, int(stats[0].Streams[0].TotalPacketsLost)) // see diff of TotalLost between pkts2 and pkts1
|
||||
}
|
||||
|
||||
func Test_OnDownStreamRTCP_SeveralTracks(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user