Repository navigation
fix(platform): order watchdog visit locks - #4518
Merged
Merged
Conversation
Acquire sandbox watchdog visit rows in immutable primary-key order before stamping them. Preserve complete batches and parallel lifecycle probes, and reproduce opposing scan-order contention in the existing real-Postgres lane. No user-facing strings, configuration or schema changes.
Contributor
Author
|
ACCEPT — reviewed exact head
No path in the reviewed change still acquires these visit row locks in a different order. |
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.
Summary
Overlapping sandbox watchdog passes could update their visited rows in opposing scan orders, deadlock after lifecycle work had committed, and report a zero result for that pass. The shared stamp helper now locks immutable row IDs in order before updating, preserving each complete visited set and the existing parallel lifecycle work.
This fixes the PostgreSQL
40P01failure observed in main Checks 37716403767. No retry, skipped row, schema change or scheduler-limit change is introduced.Checklist
bun run check --concurrency=2— 49/49 tasks passed (43 cached, six executed), pinned Bun 1.4.2 with CI environment.bun run lint:sast— passed, zero findings.Test plan
40P01. After the fix: 31/31, including complete stamps and the original rendered-session cleanup assertion.checkWatchdogslane against a fresh owned cached-image database. Hosted Backend integration must still run all required lanes against the image built from this PR.