Skip to content

fix: preserve TAE snapshot row IDs and stabilize main CI - #32957

Merged
XuPeng-SH merged 4 commits into
matrixorigin:mainfrom
XuPeng-SH:codex/main-ci-cleanup
Nov 20, 2026
Merged

XuPeng-SH merged 4 commits into
matrixorigin:mainfrom
XuPeng-SH:codex/main-ci-cleanup

Conversation

@XuPeng-SH

@XuPeng-SH XuPeng-SH commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

What type of PR is this?

  • API-change
  • BUG
  • Improvement
  • Documentation
  • Feature
  • Test and CI
  • Code Refactoring

Which issue(s) this PR fixes:

Fixes #32951
Fixes #32946
Fixes #32893
Fixes #32953
Fixes #32956

Related to #32952, #32954, #32955, #32745 and #32885. The first three issues stay open for Linux confirmation of tenant cleanup, a duration-neutral batch deadline fix, and diagnosis of the remaining embedded and multi-CN failures.

What this PR does / why we need it:

  • Seed the virtual-clock arena test with small buffers tracked by the arena memory pool. This keeps it on the real arena list and reaper path without installing a timer in the process-wide mmap cache.

  • Preserve the caller's cancellation cause throughout WAL record reads, including client checkout and retry backoff. Keep transient retries and the closed-pool error.

  • Choose a session offset distinct from the process offset in the frontend temporal test without writing the global timezone.

  • Consolidate tenant cleanup into one DROP ACCOUNT, which also removes the tenant source database. Retain the two-minute account cleanup timeout already on main from fix(enum): trim trailing spaces from ENUM labels like MySQL #32885. Four CI runs showed five tenant cases timing out at the 20-second account cleanup after their progress assertions. Both tenant scenarios retain their COPY, lock, and data assertions.

  • Preserve physical offsets when writing the snapshot of an old appendable data object. Rows without an eligible append node remain invisible placeholders so a reader that holds an existing RowID still reaches the same value after the in-memory object is replaced by its persisted snapshot. Ordinary logtail range collection stays dense.

  • Record the remaining Go test budget when a race batch starts. Keep the shared 40-minute budget, existing process pool and 120-minute outer UT watchdog.

  • Stop dependent LOAD statements after a pinned session fails and retain the existing shared SQL deadline. Run role-policy tenant cleanup through the admin pool, and check account absence only after a successful drop, within the existing SQL timeouts. Failed shared generations still retire through their current owner.

  • Enable the breaker in the morpc regression and assert the open-circuit error and nil backend. Remove the 20 ms wall-clock assertion.

Validated on Go 1.27.1 with the full frontend, objectio and WAL driver packages under race, the complete scalar refresh regression under race, the affected timezone regression with a non-UTC process timezone, and incremental formatting, vet and lint checks. The linked Linux CI runs establish the original failures.

The additional changes passed the full morpc, TAE tables and append-MVCC packages under race, the focused TAE flush and TestDelete4 cases, the role-policy and LOAD fixtures under race, and the UT scheduler harness. The sparse snapshot regression fails with the old code and passes after the fix. A separate local run replayed WAL after restart and reproduced the old panic before checking the fix. The unit test also covers modern and legacy layouts. Targeted local coverage exercised all 16 changed Go production blocks counted by the CI parser. A cold Linux runner can still reach the independent outer UT deadline.

@qodo-code-review

Copy link
Copy Markdown

Qodo reviews are paused for this user.

Troubleshooting steps vary by plan Learn more →

On a Teams plan?
Reviews resume once this user has a paid seat and their Git account is linked in Qodo.
Link Git account →

Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center?
These require an Enterprise plan - Contact us
Contact us →

@mergify

mergify Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

This pull request is merged.

@XuPeng-SH

XuPeng-SH commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor Author

mo-bot review · mo-bot-local · done

Commit: 6ad67a2c6aa3974db384ca0f589735b08a9e6232

Review completed. Read the assessment.

@XuPeng-SH XuPeng-SH left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mo-bot review · mo-bot-local · review

Commit: 6ad67a2c6aa3974db384ca0f589735b08a9e6232

Assessment: approve

WAL reads preserve the caller’s cancellation cause while retaining transient retries and the closed-pool error. The arena and timezone fixtures avoid process-global side effects while preserving their assertions. The scalar refresh test delegates tenant cleanup to DROP ACCOUNT and keeps its COPY, lock, and data checks.

Model: gpt-6.2-sol / xhigh

Session: 01a1f0a0-5126-78f3-9ab8-ef4e87f2f119 · slot 0 · generation 3

Validation:

  • Base overlays reproduced the arena timer fatal and the lost WAL cancellation cause. At the PR head, the arena regression passed 100 race runs and Test_Replayer9 passed 93. A focused probe also verified cancellation while waiting for a client and during retry backoff.

  • The full ObjectIO and WAL driver short race suites passed. All 16 scalar refresh cases passed under race, including both tenant cleanup cases. The timezone regression passed under both UTC and Asia/Shanghai.

  • The diff check, isolation preflight, and native build passed. validation-reconciliation.json matches the retained logs to their command, source, and exit receipts.

Limitations:

  • The broader frontend race suite had one unrelated failure. Test_openNewFile_nilCtx attempted to write into the read-only checkout. The affected timezone test passed in that suite.

  • Local validation did not reproduce full Linux CI contention. Ubuntu unit tests were still running in the frozen CI snapshot.

@XuPeng-SH XuPeng-SH changed the title fix: stabilize main CI test fixtures and WAL read cancellation fix: preserve TAE snapshot row IDs and stabilize main CI Nov 19, 2026
@matrix-meow matrix-meow added size/M Denotes a PR that changes [100,499] lines and removed size/S Denotes a PR that changes [10,99] lines labels Nov 19, 2026
@XuPeng-SH

XuPeng-SH commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor Author

mo-bot review · mo-bot-local · superseded

Commit: a2b191005553e6955211a341b9aa5877ad333843

PR closed or head changed

@XuPeng-SH

XuPeng-SH commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor Author

mo-bot review · mo-bot-local · done

Commit: 96c8871b06962fba06dd6e5e0e362efee5522775

Review completed. Read the assessment.

@XuPeng-SH XuPeng-SH left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mo-bot review · mo-bot-local · review

Commit: 96c8871b06962fba06dd6e5e0e362efee5522775

Assessment: approve

Snapshot flushes preserve physical RowID offsets in both existing storage layouts, and logtail range reads remain dense. WAL reads preserve the caller’s cancellation cause. The fixture changes retain their behavior checks and existing time budgets.

Model: gpt-6.2-sol / xhigh

Session: 01a1f0a0-5126-78f3-9ab8-ef4e87f2f119 · slot 0 · generation 3

Validation:

  • All 14 focused race tests passed at the assigned head, including TestDelete4 with its restart loop, the two-CN role-policy test, the LOAD cases, all 16 scalar refresh subtests, and the UT scheduler checks. See focused-race.jsonl and checks/1795114254951503698-3.json.

  • The merge-base flush code reproduced the out-of-range GetValue panic in the same regression fixture. The candidate passed with the legacy layout and with a test-only modern-layout variant. See base-flush-control.jsonl, modern-layout-race.jsonl, and checks/1795114129546872334-3.json and checks/1795114096534497796-3.json.

  • Short race suites passed for TAE tables, append MVCC, the WAL driver, morpc, and ObjectIO. The frontend timezone regression also passed in UTC and UTC−05:00. See owning-race.jsonl, timezone-utc-race.jsonl, and checks/1795114078580448745-3.json and checks/1795114164992893846-3.json.

  • Isolation preflight, the native build, the diff check, and shell syntax validation passed. The discussion ledger accounts for all six frozen entries.

Limitations:

  • Full Ubuntu race UT, coverage, and multi-CN BVT were still running in the frozen CI snapshot. Issues #32952, #32954, and #32955 remain open for full-lane confirmation and diagnosis.

This branch was successfully deployed

No deployments
ci — fb75bffd Deployed Nov 20, 2026 by XuPeng-SH
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/bug Something isn't working kind/test-ci size/M Denotes a PR that changes [100,499] lines

Projects

None yet

3 participants