Skip to content

[4.2-dev] Stabilize lock and clone race tests - #33685

Merged
XuPeng-SH merged 1 commit into
matrixorigin:4.2-devfrom
XuPeng-SH:codex/42-lock-clone-ut-flakes
Dec 2, 2026
Merged

XuPeng-SH merged 1 commit into
matrixorigin:4.2-devfrom
XuPeng-SH:codex/42-lock-clone-ut-flakes

Conversation

@XuPeng-SH

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 #33657

Related to #29165 and the x86 race UT failures.

What this PR does / why we need it:

  • Backport the deterministic duplicate-bind regression from test(lockservice): bound concurrent duplicate bind regression #29171. Two transactions hold shared locks while competing callbacks deliver duplicate binds. The test still verifies table identity, no replacement or fencing, and successful subsequent locking and cleanup.
  • Run the mutable-tail restart case on two CNs with a test-owned data directory. Retain the cross-CN writes, restart, persisted data and transaction rollback assertions. The post-restart phase has its own deadline and refreshes the restarted CN's TN routing snapshot before beginning the write transaction. A deferred rollback covers assertion failures. Closing the private cluster and removing its directory replaces SQL teardown.
  • Run the system-catalog clone scenario through the connection pool with a separate cleanup deadline for each database. Cancelling one DROP can no longer close the connection used by subsequent view scenarios.

Local validation uses Go 1.26.4 on Linux x86_64 with the CI race flags. The three formerly failing tests and the affected fixture checks passed on the final revision. The full lockservice race suite passed. The duplicate-bind case passed 100 race iterations, and the mutable-tail restart passed two additional race iterations. Incremental SCA passed for pkg/embed and pkg/lockservice.

@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 Dec 2, 2026 •

Copy link
Copy Markdown
Contributor

This pull request is merged.

@XuPeng-SH
XuPeng-SH merged commit bcad244 into matrixorigin:4.2-dev Dec 2, 2026
17 of 22 checks passed
@XuPeng-SH
XuPeng-SH deleted the codex/42-lock-clone-ut-flakes branch December 2, 2026 13:55

This branch was successfully deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/test-ci size/M Denotes a PR that changes [100,499] lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants