Repository navigation
Description
Is there an existing issue for the same bug?
- I checked related issues.
- Related but not exact: [Bug]: Ubuntu UT job cascades across packages after cluster and checkpoint timeouts #26519 tracks a broader Ubuntu UT embedded-cluster and HAKeeper timeout cascade and is closed.
- Related but different: [Bug]: main Ubuntu/x86 race UT has embedded-cluster readiness flaky failures #27986 mentions the same regression test, but its latest analysis attributes the failure to fix(view): activate durable metadata refresh #27734 view-metadata admission behavior.
- [Bug]: DATA BRANCH CREATE DATABASE rejects valid cyclic foreign-key schemas #26111 is the original cyclic foreign-key data-branch product bug and is already fixed. This issue tracks test and cluster instability, not a regression of that feature.
Environment
- Repository: matrixorigin/matrixone
- Branch: main
- Workflow: MatrixOne ALL CI
- Failed run: https://github.com/matrixorigin/matrixone/actions/runs/33727978045
- Failed job: https://github.com/matrixorigin/matrixone/actions/runs/33727978045/job/100561268294
- PR under validation: fix: implement STATEMENT_DIGEST_TEXT #27990
- Tested head: b1d6b20
- Failure date: 2026-09-03
Actual behavior
The Ubuntu/x86 UT job failed only in:
github.com/matrixorigin/matrixone/pkg/tests/issues/isolated
TestIssue26111DataBranchDatabaseWithCyclicForeignKeys
The business assertions were not reported as failing. During cleanup, the test received:
Received unexpected error:
context deadline exceeded
exec failed: drop database if exists issue_26111_branch
The surrounding service logs also reported the CN/backend becoming unavailable, including:
dial tcp4 127.0.0.1:10102: connect: connection refused
The test ran for 61.93 seconds before failing. The package was the only failed UT package.
Flakiness evidence
The same exact test passed in later successful Ubuntu/x86 UT jobs:
- https://github.com/matrixorigin/matrixone/actions/runs/33773302890/job/100708752127: pass, 40.23s
- https://github.com/matrixorigin/matrixone/actions/runs/33777811772/job/100723881283: pass, 33.77s
- https://github.com/matrixorigin/matrixone/actions/runs/33783139394/job/100741454685: pass, 41.53s
- https://github.com/matrixorigin/matrixone/actions/runs/33788600485/job/100759467845: pass, 39.43s
This strongly indicates a timing and load-sensitive embedded-cluster or teardown lifecycle failure rather than a deterministic regression in #27990. #27990 changes statement-digest parsing and planning and does not modify this test, embedded-cluster startup, CN/TN lifecycle, HAKeeper, or data-branch cleanup.
Expected behavior
- A healthy embedded cluster should allow test cleanup to finish within its bounded context.
- A transient CN/TN/backend loss should produce an actionable cluster-lifecycle diagnosis, not an unrelated product-test failure.
- Test cleanup must remain bounded and must not leave branch or database state that contaminates later tests.
- The regression test must retain strict assertions for cyclic-FK data-branch correctness. Do not fix this by weakening assertions or adding blind sleeps or retries.
Investigation and acceptance criteria
- Identify the first causal event before the drop database timeout: embedded-cluster readiness or liveness loss, HAKeeper/TN/CN failure, lockservice/backend failure, or test cleanup ordering.
- Reproduce the failure under CI-equivalent Ubuntu/x86 UT parallelism, or provide a clean-main recurrence proving it is independent of the validating PR.
- Verify success, timeout, cancellation, partial cleanup, and repeated-test paths for the test cluster and branch database.
- Ensure failed cleanup cannot leak state or poison subsequent tests.
- Preserve the original [Bug]: DATA BRANCH CREATE DATABASE rejects valid cyclic foreign-key schemas #26111 business oracle and demonstrate repeated successful runs after the fix.
- Record exact commit, runner, package parallelism, test duration, and terminal result for validation.
Current classification: flaky test-infrastructure lifecycle issue; root cause is not yet proven.
Activity
XuPeng-SH commentedon Sep 3, 2026
Root cause is now proven from the failed-job timeline and source ownership:
08:17:32.61;DROP ACCOUNT, snapshot cleanup, and four database drops;DROP ACCOUNTexpands into many tenant-catalog DDL/DML operations and consumed almost the whole budget on the loaded runner;DROP DATABASE issue_26111_branchwas the next operation and was canceled when that shared cleanup deadline expired;connection refusedmessages appeared during the subsequent cluster shutdown and are downstream noise, not the initiating cause.The test already owns a fresh embedded cluster and unique data path, so SQL pre-clean and teardown are redundant and scale-dependent. PR #28099 removes that second cleanup owner while retaining connection close, cluster close, and every data-branch/FK oracle. It does not increase timeouts, add retries, or weaken assertions.
Validation on exact change:
15.85s)19.22s, count 1 per adaptive budget)13.04s,12.97s,12.92s)134.53s)Fix: #28099
test: remove redundant data branch teardown (#28099)
test: remove redundant data branch teardown (matrixorigin#28099)
test: remove redundant data branch teardown (matrixorigin#28099)
test: remove redundant data branch teardown (matrixorigin#28099)