docs: members-only matchmaking at scale — design log (DO NOT MERGE yet)#475
Draft
metis-sprock wants to merge 4 commits into
Draft
docs: members-only matchmaking at scale — design log (DO NOT MERGE yet)#475metis-sprock wants to merge 4 commits into
metis-sprock wants to merge 4 commits into
Conversation
When replaceTicket fires after a late arrival cancellation (or any fallback rebuild), the party handler is now re-queried for the current member list. Previously the stale snapshot from configureParty was reused, causing rebuilt tickets to have presences=1 even when new members had joined. Root cause: cancelTicketForLateArrival called MatchmakerRemoveAll which only removes tickets keyed by party ID. When the leader initially had a party of 1, addTicket takes the solo path and creates a ticket with an empty party ID. MatchmakerRemoveAll could not find or cancel it. Fix: - cancelTicketForLateArrival now also calls RemoveSessionAll to cancel solo tickets that have no party ID - Added a ticketRebuildCh channel on PartyHandler so the late arrival can signal the leader's lobbyMatchMakeWithFallback loop to rebuild immediately instead of waiting for the fallback timer - lobbyMatchMakeWithFallback selects on ticketRebuildCh alongside the existing fallback and timeout timers Observed in production: leader submitted 3 consecutive solo tickets while a party member was present and triggering cancellation each time. Fixes #459
When a player is in an active Arena/Combat match, party follow events are now ignored. The party waits until the player returns to social. Also adds a fast-path check (isFollowerAlreadyInLeaderMatch) to skip redundant follow processing when the follower is already in the leader's match, preventing unnecessary "Joined party group" churn. Observed in production: player mid-match was yanked back to social when their party leader hit matchmaking. Fixes #460
When the party follow path directs a player to a social lobby they're already in, it's now silently treated as success instead of producing an error. Fixes #462
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Draft / discussion artifact — do not merge. Resume point for the members-only-at-scale design.
Captures the full design + the grounded current-state (with file:line citations) so we don't re-investigate when we come back:
RoleCacheblob with O(guild-size) write-amplification per change + 60s full reload; gate Branch A (in-mem) vs Branch B (live Discord on the hot path, fails open); purely lazy population;GuildMemberAddno-op; no role-change handlers; no JWT claims; 30s deny-retry already exists.Next: get EVRL's config, run through
/review-plan, then scope implementation. Related: #228, #467.