Repository navigation
test(tae): fix checkpoint leak replay setup - #26379
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 c9ae5ea. The test now creates DB/table metadata through the production-equivalent helpers that persist mo_database/mo_tables/mo_columns, while replay error behavior remains unchanged. Refreshing db after Restart is required so post-reopen cleaner checks observe the reopened engine rather than the closed instance. No assertion was weakened and no cleanup was bypassed. TestCkpLeak passes 10 consecutive local runs; latest required CI is green and the head merges cleanly with latest main.
Merge Queue Status
This pull request spent 1 hour 21 minutes 42 seconds in the queue, including 39 minutes 1 second running CI. Required conditions to merge
|
`TestCkpLeak` created its database and relations through low-level TAE catalog APIs. Those APIs did not persist the corresponding rows to `mo_database`, `mo_tables`, and `mo_columns`. Recovery now rebuilds the catalog from these system tables, so WAL replay could not resolve the user database and table and panicked with `ExpectedEOB`. This change: - creates the test database and relations with the helpers that persist all three system catalog tables; - refreshes the local DB reference after `tae.Restart` so the cleaner checks use the reopened DB; - keeps replay error handling unchanged, avoiding any suppression of missing-catalog or data-loss errors. Validation: - `TestCkpLeak`: 100 repeated non-race runs; - `TestCkpLeak`: 19 repeated race runs on the latest `main`; - full `pkg/vm/engine/tae/db/test` package under the race detector; - `make static-check`; - `git diff --check` and gofmt verification. Approved by: @XuPeng-SH
`TestCkpLeak` created its database and relations through low-level TAE catalog APIs. Those APIs did not persist the corresponding rows to `mo_database`, `mo_tables`, and `mo_columns`. Recovery now rebuilds the catalog from these system tables, so WAL replay could not resolve the user database and table and panicked with `ExpectedEOB`. This change: - creates the test database and relations with the helpers that persist all three system catalog tables; - refreshes the local DB reference after `tae.Restart` so the cleaner checks use the reopened DB; - keeps replay error handling unchanged, avoiding any suppression of missing-catalog or data-loss errors. Validation: - `TestCkpLeak`: 100 repeated non-race runs; - `TestCkpLeak`: 19 repeated race runs on the latest `main`; - full `pkg/vm/engine/tae/db/test` package under the race detector; - `make static-check`; - `git diff --check` and gofmt verification. Approved by: @XuPeng-SH
`TestCkpLeak` created its database and relations through low-level TAE catalog APIs. Those APIs did not persist the corresponding rows to `mo_database`, `mo_tables`, and `mo_columns`. Recovery now rebuilds the catalog from these system tables, so WAL replay could not resolve the user database and table and panicked with `ExpectedEOB`. This change: - creates the test database and relations with the helpers that persist all three system catalog tables; - refreshes the local DB reference after `tae.Restart` so the cleaner checks use the reopened DB; - keeps replay error handling unchanged, avoiding any suppression of missing-catalog or data-loss errors. Validation: - `TestCkpLeak`: 100 repeated non-race runs; - `TestCkpLeak`: 19 repeated race runs on the latest `main`; - full `pkg/vm/engine/tae/db/test` package under the race detector; - `make static-check`; - `git diff --check` and gofmt verification. Approved by: @XuPeng-SH
What type of PR is this?
Which issue(s) this PR fixes:
Fixes #26364
What this PR does / why we need it:
TestCkpLeakcreated its database and relations through low-level TAE catalogAPIs. Those APIs did not persist the corresponding rows to
mo_database,mo_tables, andmo_columns. Recovery now rebuilds the catalog from thesesystem tables, so WAL replay could not resolve the user database and table and
panicked with
ExpectedEOB.This change:
three system catalog tables;
tae.Restartso the cleaner checks usethe reopened DB;
missing-catalog or data-loss errors.
Validation:
TestCkpLeak: 100 repeated non-race runs;TestCkpLeak: 19 repeated race runs on the latestmain;pkg/vm/engine/tae/db/testpackage under the race detector;make static-check;git diff --checkand gofmt verification.