Files
livekit/pkg
Raja SubramanianandClaude Opus 5 5528c464a0 telemetry: support roomID change for a participant (#4816)
* telemetry: support roomID change for a participant

A room can get a new id while participants are connected. Key stats
workers as map[roomID]map[participantID] so moving a room is a single
map splice, and add reKeyRoom/RoomIDChanged to do the move.

Stats collected before the change are sealed off with the room they
were collected in so they stay attributed to it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* telemetry: close superseded worker on re-key collision

Only one worker can be keyed at (room, participant). If a re-key lands
on a room that already has a worker for the same participant, keep the
one already filed there and close the superseded one so it drains and
is reaped instead of lingering in the flush list.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* telemetry: hand references to the successor on force close

A ReferenceGuard records that it activated some worker, not which one,
so a superseded worker cannot just drop its references - the survivor
would be left with references it never sees released and would never
close. Hand them over instead.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-29 12:58:22 +05:30
..
2026-08-14 16:26:08 +08:00
2025-11-28 21:51:53 +05:30
2026-07-26 22:26:41 +05:30