Repository navigation
fix(test): wait for failed ICKP cleanup - #26679
Conversation
Qodo reviews are paused for this user.Troubleshooting steps vary by plan Learn more → On a Teams plan? Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center? |
XuPeng-SH
left a comment
There was a problem hiding this comment.
Deep-reviewed exact head 8ca9155.
The test now waits across both asynchronous ownership boundaries: intent retirement closes the admitted/queued window, and WaitRunningCKPDoneForTest closes the runner-owned execution and deferred unpublished-object cleanup window. The wait is bounded by TestCheckpointTimeout, production checkpoint behavior is untouched, and the original strict file-service rollback oracle remains.
Focused validation passed 10 consecutive runs plus 3 race runs. No blocking Q1 cleanup, Q2 termination, determinism, or assertion-quality findings.
Merge Queue Status
This pull request spent 28 minutes 3 seconds in the queue, with no time running CI. Waiting for
All conditions
ReasonPull request #26679 has been dequeued Pull request from fork cannot be queued. This pull request comes from a fork, and Mergify needs the author's permission to update its branch.
Failing checks:
HintYou should look at the reason for the failure and decide if the pull request needs to be fixed or if you want to requeue it. Tick the box to put this pull request back in the merge queue (same as
|
## What type of PR is this? - [ ] API-change - [ ] BUG - [ ] Improvement - [ ] Documentation - [ ] Feature - [x] Test and CI - [ ] Code Refactoring ## Which issue(s) this PR fixes: Fixes matrixorigin#26583 ## What this PR does / why we need it: ### Root cause The object reported by `Test_CheckpointChaos1` was observed before the failed ICKP reached its terminal cleanup boundary; it was not a post-cleanup leak. `ForceCheckpoint` stops waiting when its caller context expires, but an already admitted ICKP runs under the checkpoint executor context. In the failing CI timeline, `ForceCheckpoint` returned on the one-second deadline while the runner-owned ICKP was still deleting its unpublished data and table-ID objects. The test immediately took a file-service snapshot and could therefore observe one transient 760-byte object. ### Change After the expected caller timeout, the test now waits for both sides of the asynchronous boundary: - the queued/running ICKP intent reaches retirement; - the runner-owned checkpoint execution finishes cleanup. Only then does it assert that the file-service snapshot is unchanged. The strict rollback assertion remains; production checkpoint cancellation and cleanup semantics are unchanged. The intent wait closes the enqueue-before-running window, while the existing runner job barrier closes the interval between intent retirement and completion of unpublished-object deletion. ### Validation Based on current main `c726a6199094`: - focused `Test_CheckpointChaos1` under `-race`: measured 1.02s; - adaptive race stress with a 30s budget: `-race -count=29` passed in 30.722s; - full `pkg/vm/engine/tae/db/test` under `-race`: passed in 77.015s; - full package in normal mode: passed in 54.172s; - owning-package `go vet`: passed; - `gofmt` and `git diff --check`: passed. Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
## What type of PR is this? - [ ] API-change - [ ] BUG - [ ] Improvement - [ ] Documentation - [ ] Feature - [x] Test and CI - [ ] Code Refactoring ## Which issue(s) this PR fixes: Fixes matrixorigin#26583 ## What this PR does / why we need it: ### Root cause The object reported by `Test_CheckpointChaos1` was observed before the failed ICKP reached its terminal cleanup boundary; it was not a post-cleanup leak. `ForceCheckpoint` stops waiting when its caller context expires, but an already admitted ICKP runs under the checkpoint executor context. In the failing CI timeline, `ForceCheckpoint` returned on the one-second deadline while the runner-owned ICKP was still deleting its unpublished data and table-ID objects. The test immediately took a file-service snapshot and could therefore observe one transient 760-byte object. ### Change After the expected caller timeout, the test now waits for both sides of the asynchronous boundary: - the queued/running ICKP intent reaches retirement; - the runner-owned checkpoint execution finishes cleanup. Only then does it assert that the file-service snapshot is unchanged. The strict rollback assertion remains; production checkpoint cancellation and cleanup semantics are unchanged. The intent wait closes the enqueue-before-running window, while the existing runner job barrier closes the interval between intent retirement and completion of unpublished-object deletion. ### Validation Based on current main `c726a6199094`: - focused `Test_CheckpointChaos1` under `-race`: measured 1.02s; - adaptive race stress with a 30s budget: `-race -count=29` passed in 30.722s; - full `pkg/vm/engine/tae/db/test` under `-race`: passed in 77.015s; - full package in normal mode: passed in 54.172s; - owning-package `go vet`: passed; - `gofmt` and `git diff --check`: passed. Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
## What type of PR is this? - [ ] API-change - [ ] BUG - [ ] Improvement - [ ] Documentation - [ ] Feature - [x] Test and CI - [ ] Code Refactoring ## Which issue(s) this PR fixes: Fixes matrixorigin#26583 ## What this PR does / why we need it: ### Root cause The object reported by `Test_CheckpointChaos1` was observed before the failed ICKP reached its terminal cleanup boundary; it was not a post-cleanup leak. `ForceCheckpoint` stops waiting when its caller context expires, but an already admitted ICKP runs under the checkpoint executor context. In the failing CI timeline, `ForceCheckpoint` returned on the one-second deadline while the runner-owned ICKP was still deleting its unpublished data and table-ID objects. The test immediately took a file-service snapshot and could therefore observe one transient 760-byte object. ### Change After the expected caller timeout, the test now waits for both sides of the asynchronous boundary: - the queued/running ICKP intent reaches retirement; - the runner-owned checkpoint execution finishes cleanup. Only then does it assert that the file-service snapshot is unchanged. The strict rollback assertion remains; production checkpoint cancellation and cleanup semantics are unchanged. The intent wait closes the enqueue-before-running window, while the existing runner job barrier closes the interval between intent retirement and completion of unpublished-object deletion. ### Validation Based on current main `c726a6199094`: - focused `Test_CheckpointChaos1` under `-race`: measured 1.02s; - adaptive race stress with a 30s budget: `-race -count=29` passed in 30.722s; - full `pkg/vm/engine/tae/db/test` under `-race`: passed in 77.015s; - full package in normal mode: passed in 54.172s; - owning-package `go vet`: passed; - `gofmt` and `git diff --check`: passed. Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
What type of PR is this?
Which issue(s) this PR fixes:
Fixes #26583
What this PR does / why we need it:
Root cause
The object reported by
Test_CheckpointChaos1was observed before the failed ICKP reached its terminal cleanup boundary; it was not a post-cleanup leak.ForceCheckpointstops waiting when its caller context expires, but an already admitted ICKP runs under the checkpoint executor context. In the failing CI timeline,ForceCheckpointreturned on the one-second deadline while the runner-owned ICKP was still deleting its unpublished data and table-ID objects. The test immediately took a file-service snapshot and could therefore observe one transient 760-byte object.Change
After the expected caller timeout, the test now waits for both sides of the asynchronous boundary:
Only then does it assert that the file-service snapshot is unchanged. The strict rollback assertion remains; production checkpoint cancellation and cleanup semantics are unchanged.
The intent wait closes the enqueue-before-running window, while the existing runner job barrier closes the interval between intent retirement and completion of unpublished-object deletion.
Validation
Based on current main
c726a6199094:Test_CheckpointChaos1under-race: measured 1.02s;-race -count=29passed in 30.722s;pkg/vm/engine/tae/db/testunder-race: passed in 77.015s;go vet: passed;gofmtandgit diff --check: passed.