Repository navigation
Description
Is there an existing issue for the same bug?
- I have checked the existing issues.
The original product bug #27666 is closed. Its comments record this exact test-failure signature on an unrelated PR, but no open issue tracks the recurring test failure.
Branch Name
agent/issue-28277-c4ea83b7
Commit ID
167bc74dca30644abf6222a82895dd9026b1ddbb
Other Environment Information
- Hardware parameters: GitHub-hosted runner
- OS type: Ubuntu/x86
- Others: MatrixOne UT Coverage; run 34024743134, job 101463652870, attempt 1
Actual Behavior
pkg/tests/issues.TestIssue27666CDCWatermarkWriteSerializesWithDrop/writer_wins intermittently waits 30 seconds without observing a waiter on the mo_cdc_task row lock:
Error: Condition never satisfied
Test: TestIssue27666CDCWatermarkWriteSerializesWithDrop/writer_wins
Messages: contender did not wait for the holder task-row lock
The coverage diagnostics report this as the only failed test; there are no build failures. The failure occurs at the pre-release lock-waiter assertion in issue_27666_test.go:127.
This exact signature was previously recorded in #27666 comment 5549595856 on unrelated PR #28145. On the current failing head, the focused command passed 3/3 locally in 15.245 seconds:
.agents/skills/mo-dev/scripts/mo-cgo-test -run ^TestIssue27666CDCWatermarkWriteSerializesWithDrop$ -count=3 -timeout=180s ./pkg/tests/issues
ok github.com/matrixorigin/matrixone/pkg/tests/issues 15.245s
PR #28278 changes remote-pipeline terminal-error and cancellation handling plus its tests. It does not change pkg/tests/issues, CDC, catalog locking, lockservice, or the internal SQL executor. The failed assertion runs before the test cancels either transaction, so none of the changed cancellation/error-arbitration paths is active.
Expected Behavior
The two-CN CDC race regression should deterministically observe the contender blocked behind the holder in both lock orderings, or report enough transaction/lock state to distinguish an implementation regression from an observation race.
Steps to Reproduce
- Run the coverage unit-test suite on a two-CN embedded configuration.
- Execute
TestIssue27666CDCWatermarkWriteSerializesWithDrop. - In the intermittent failure, observe that
drop_winspasses andwriter_winstimes out inclusterHasLockWaiterafter 30 seconds. - Re-run the exact focused test; it may pass, as it did 3/3 on the failing head.
Additional information
- Failed run attempt: 1.
- Failed job completed at
2026-09-06T09:54:05Z. - The test entered main through PR fix(cdc): prevent watermark recreation after drop #27989 / commit
57af20eef8. - Investigation should determine whether the contender is not acquiring the expected task-row lock or whether
clusterHasLockWaitercan miss a valid remote/bound lock waiter. The test should not be weakened without proving the intended serialization and final task/watermark atomicity.
Activity
gouhongshen commentedon Sep 6, 2026
PR #28283 is trying to fix this issue.
test(cdc): stabilize watermark drop race observation (#28283)
gouhongshen commentedon Sep 6, 2026
PR #28283 has merged and is awaiting manual validation. The issue remains open.
gouhongshen commentedon Sep 8, 2026
Reopening: Matrixone UT Coverage failed again on run 34222510623, job 102049428094, attempt 1.
TestIssue27666CDCWatermarkWriteSerializesWithDrop/drop_winstimed out after 30 seconds because no contender waiter was observed for the holder transaction. PR #28291 changes only fourpkg/fileservicetest files, so it cannot affect this CDC/lock-observation path. This is the same two-CN lock-waiter observability contract tracked here, now reproducing in the opposite lock ordering. The failed job will be rerun once under the CI policy.XuPeng-SH commentedon Sep 9, 2026
Root cause and fix update
This is the same failure tracked by this issue; no duplicate issue was opened.
The failure was a test precondition race, not a
GetWaitingListfalse negative. The fixture row was committed through CN0, but CN1 had not necessarily consumed the corresponding logtail yet. Indrop_wins, the guarded watermark INSERT on CN1 could therefore complete withAffectedRows=0before it requested the task-row lock, so the holder wait graph correctly contained no contender.Commit
e5e7c1bacffixes the test contract by:Validation on the candidate:
-race: pass;-race -count=3: pass;TestIssue28313EmptyRemoteDispatchflaky skipped: pass;go vetwith repository CGo headers/libs andgit diff --check: pass.XuPeng-SH commentedon Sep 9, 2026
修复 PR 已提交:#28542(https://github.com/matrixorigin/matrixone/pull/28542),目标是消除跨 CN logtail 可见性前置条件竞态并改善提前完成诊断。
test(cdc): synchronize cross-CN watermark race fixture (#28542)
fix: correct JSON comparison precedence (#28086)
test(cdc): stabilize watermark drop race observation (matrixorigin#28283
test(cdc): synchronize cross-CN watermark race fixture (matrixorigin#…
fix: correct JSON comparison precedence (matrixorigin#28086)
test(cdc): stabilize watermark drop race observation (matrixorigin#28283
test(cdc): synchronize cross-CN watermark race fixture (matrixorigin#…
fix: correct JSON comparison precedence (matrixorigin#28086)
test(cdc): stabilize watermark drop race observation (matrixorigin#28283
test(cdc): synchronize cross-CN watermark race fixture (matrixorigin#…
fix: correct JSON comparison precedence (matrixorigin#28086)