publish stream stats to prometheus (#1313)

* add prometheus stats for rtt/jitter/packet loss

* add track source to metrics

* better packet loss bins

* add track type to metrics

* remove source from AnalyticsStat

* regenerate telemetry service fake

* compute loss from per stream packet count
This commit is contained in:
Paul Wells
2023-01-19 19:37:15 -08:00
committed by GitHub
parent 6a8e86c3a3
commit 1ef7c46fd7
8 changed files with 135 additions and 47 deletions
+1 -1
View File
@@ -16,7 +16,7 @@ import (
//go:generate go run github.com/maxbrunsfeld/counterfeiter/v6 . TelemetryService
type TelemetryService interface {
// TrackStats is called periodically for each track in both directions (published/subscribed)
TrackStats(streamType livekit.StreamType, participantID livekit.ParticipantID, trackID livekit.TrackID, stat *livekit.AnalyticsStat)
TrackStats(key StatsKey, stat *livekit.AnalyticsStat)
// events
RoomStarted(ctx context.Context, room *livekit.Room)