fix(collab): keep surviving co-editor admitted during roomKey rotation - #30
Merged
Merged
Conversation
The editbound cleanup (#29) swapped the live gp-actor edit re-check from a per-actor-handle check to a doc-wide minEditEpoch floor. On removal the client evicts the removed actor with the bumped gateEpoch, stamping the floor doc-wide before the make-before-break rotation re-issues survivors a fresh-epoch editUcan at cutover. In the gap every surviving co-editor (admitted at the old epoch) fails isStillAdmitted and is disconnected, so it misses the one-shot /session/cutover and is stranded with "Session not found" until a full refresh. isStillAdmitted now tolerates a below-floor gp-actor while a make-before-break rotation for the doc is in flight (rotationCoordinator.isActive). JOIN admission (resolveEditAdmission) stays strict, so the removed actor still cannot rejoin. Unit-verified (socket-handlers.isStillAdmitted.rotationGrace.test.ts); not yet E2E-verified. Known residual windows (evict->begin gap, post-cutover drain, and the doc-wide grace briefly re-admitting an evict-failed actor) are tracked for a follow-up hardening (per-doc evicted-handle denylist).
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.
The editbound cleanup (#29) swapped the live gp-actor edit re-check from a
per-actor-handle check to a doc-wide minEditEpoch floor. On removal the client
evicts the removed actor with the bumped gateEpoch, stamping the floor doc-wide
before the make-before-break rotation re-issues survivors a fresh-epoch editUcan
at cutover. In the gap every surviving co-editor (admitted at the old epoch)
fails isStillAdmitted and is disconnected, so it misses the one-shot
/session/cutover and is stranded with "Session not found" until a full refresh.
isStillAdmitted now tolerates a below-floor gp-actor while a make-before-break
rotation for the doc is in flight (rotationCoordinator.isActive). JOIN admission
(resolveEditAdmission) stays strict, so the removed actor still cannot rejoin.
Unit-verified (socket-handlers.isStillAdmitted.rotationGrace.test.ts); not yet
E2E-verified. Known residual windows (evict->begin gap, post-cutover drain, and
the doc-wide grace briefly re-admitting an evict-failed actor) are tracked for a
follow-up hardening (per-doc evicted-handle denylist).