mirror of
https://github.com/livekit/livekit.git
synced 2026-10-15 15:30:14 +00:00
GetRecentlyDisconnectedParticipants walked the participant update cache with Get, which moves each entry to the front of the LRU. Walking from newest to oldest left the cache in reverse order, so after a reconnect the next updates evicted the most recently updated participants first. In a room where the subscriber has tracked 128 or more participants, a participant that had just disconnected was then dropped from the cache and a later reconnect did not report it as disconnected, and the out-of-order version check was lost for recently updated participants. Use Peek, which reads an entry without changing its recency.