A couple of logging tweaks (#1276)

This commit is contained in:
Raja Subramanian
2022-12-30 19:47:25 +05:30
committed by GitHub
parent c393a5f8dd
commit 5532dfa75c
2 changed files with 3 additions and 3 deletions

View File

@@ -245,7 +245,7 @@ func (r *Room) Join(participant types.LocalParticipant, opts *ParticipantOptions
// it's important to set this before connection, we don't want to miss out on any publishedTracks
participant.OnTrackPublished(r.onTrackPublished)
participant.OnStateChange(func(p types.LocalParticipant, oldState livekit.ParticipantInfo_State) {
r.Logger.Debugw("participant state changed",
r.Logger.Infow("participant state changed",
"state", p.State(),
"participant", p.Identity(),
"pID", p.ID(),
@@ -408,7 +408,7 @@ func (r *Room) RemoveParticipant(identity livekit.ParticipantIdentity, pID livek
p.OnSubscribedTo(nil)
// close participant as well
r.Logger.Infow("closing participant for removal", "pID", p.ID(), "participant", p.Identity())
r.Logger.Debugw("closing participant for removal", "pID", p.ID(), "participant", p.Identity())
_ = p.Close(true, reason)
r.lock.RLock()

View File

@@ -717,7 +717,7 @@ func (d *DownTrack) CloseWithFlush(flush bool) {
d.receiver.DeleteDownTrack(d.subscriberID)
if d.rtcpReader != nil {
logger.Debugw("downtrack close rtcp reader")
d.logger.Debugw("downtrack close rtcp reader")
d.rtcpReader.Close()
d.rtcpReader.OnPacket(nil)
}