mirror of
https://github.com/livekit/livekit.git
synced 2026-07-28 09:59:26 +00:00
log when auto egress fails (#1029)
* log when auto egress fails * use room logger
This commit is contained in:
+4
-2
@@ -732,7 +732,7 @@ func (r *Room) onTrackPublished(participant types.LocalParticipant, track types.
|
||||
|
||||
// auto track egress
|
||||
if r.internal != nil && r.internal.TrackEgress != nil {
|
||||
StartTrackEgress(
|
||||
if err := StartTrackEgress(
|
||||
context.Background(),
|
||||
r.egressLauncher,
|
||||
r.telemetry,
|
||||
@@ -740,7 +740,9 @@ func (r *Room) onTrackPublished(participant types.LocalParticipant, track types.
|
||||
track,
|
||||
r.Name(),
|
||||
r.ID(),
|
||||
)
|
||||
); err != nil {
|
||||
r.Logger.Errorw("failed to launch track egress", err)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -25,7 +25,7 @@ func StartTrackEgress(
|
||||
track types.MediaTrack,
|
||||
roomName livekit.RoomName,
|
||||
roomID livekit.RoomID,
|
||||
) {
|
||||
) error {
|
||||
if req, err := startTrackEgress(ctx, launcher, opts, track, roomName, roomID); err != nil {
|
||||
// send egress failed webhook
|
||||
ts.NotifyEvent(ctx, &livekit.WebhookEvent{
|
||||
@@ -38,7 +38,9 @@ func StartTrackEgress(
|
||||
Request: &livekit.EgressInfo_Track{Track: req},
|
||||
},
|
||||
})
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func startTrackEgress(
|
||||
|
||||
Reference in New Issue
Block a user