refresh telemetry guard on participant move (#4280)

This commit is contained in:
Raja Subramanian
2026-02-03 15:34:16 +05:30
committed by GitHub
parent 333f0349d1
commit d2bae34d53
+7
View File
@@ -919,6 +919,9 @@ func (p *ParticipantImpl) ToProto() *livekit.ParticipantInfo {
}
func (p *ParticipantImpl) TelemetryGuard() *telemetry.ReferenceGuard {
p.lock.RLock()
defer p.lock.RUnlock()
return p.telemetryGuard
}
@@ -4015,6 +4018,10 @@ func (p *ParticipantImpl) MoveToRoom(params types.MoveToRoomParams) {
p.params.Logger.Infow("move participant to new room", "newRoomName", params.RoomName, "newID", params.ParticipantID)
p.lock.Lock()
p.telemetryGuard = &telemetry.ReferenceGuard{}
p.lock.Unlock()
p.params.LoggerResolver.Reset()
p.params.ReporterResolver.Reset()
p.setListener(params.Listener)