Repository navigation
Description
Is there an existing issue for the same bug?
- I have checked the existing issues.
Issue #24618 tracks a different failure signature in the same test
(transaction ... has been committed or aborted). This report tracks a
HAKeeper/logservice connection reset before the test database can be created.
Branch Name
main
Commit ID
Other Environment Information
- Hardware parameters: GitHub Actions hosted runner
- OS type: Ubuntu/x86
- Go version: 1.26.4
- Workflow: MatrixOne ALL CI, UT Test on Ubuntu/x86
Actual Behavior
TestPartitionBasedShardCanBeCreated in pkg/tests/shard failed while creating
its test database:
logservice/store.go:813 propose failed: invalid deadline
hakeeper_client.go:464 failed to allocate id:
writeto tcp4 127.0.0.1:54666->127.0.0.1:16020:
read tcp4 127.0.0.1:54666->127.0.0.1:16020:
read: connection reset by peer
--- FAIL: TestPartitionBasedShardCanBeCreated (41.08s)
The embedded cluster also reported that the system was busy and CN heartbeats
exceeded their deadlines immediately before the logservice connection reset.
This was observed on PR #26021. That PR does not change pkg/tests/shard,
pkg/shardservice, or the embedded test-cluster setup. The focused test passed
once on the PR head and five consecutive times on a clean main worktree at
1ac64a870, which indicates an intermittent infrastructure or embedded-cluster
lifecycle failure rather than a deterministic assertion failure.
Expected Behavior
The embedded HAKeeper/logservice connection should remain available throughout
test setup, and TestPartitionBasedShardCanBeCreated should not fail because
the service connection is reset.
Steps to Reproduce
make ut
Focused diagnostic command:
.agents/skills/mo-dev/scripts/mo-cgo-test \
-v -count=5 -timeout=300s \
-run '^TestPartitionBasedShardCanBeCreated$' \
./pkg/tests/shard
The failure is intermittent and has currently only been observed in the full
Ubuntu/x86 CI UT workload.
Additional information
Relevant sequence from the CI log:
system is busy {"expect": "1s", "actual": "3.284240492s"}
failed to send cn heartbeat: context deadline exceeded
propose failed: invalid deadline
failed to allocate id: ... connection reset by peer
Activity
LeftHandCold commentedon Jul 27, 2026
Another occurrence with the same HAKeeper/logservice failure signature was observed on PR #26096.
Failure chain from the job log:
This occurred in the heavy race-test phase (go test -race, package parallelism 3). The same test passed on the exact same PR head in the coverage UT job in 13.2s, and a focused local race run also passed:
PR #26096 does not change pkg/tests/dml, pkg/embed, pkg/logservice, pkg/cnservice, pkg/tnservice, or pkg/common/morpc. This is therefore another intermittent full-race-workload occurrence rather than a deterministic regression from that PR. The delayed Dragonboat tick batches immediately before HAKeeper deadlines provide additional evidence that runner scheduling/resource pressure is the trigger; the embedded cluster currently does not tolerate that delay without dropping control-plane RPCs.
gouhongshen commentedon Jul 30, 2026
A new occurrence with the same embedded HAKeeper/TN connection-reset signature appeared in PR #26369's third Ubuntu/x86 UT attempt.
d605d6e0509ba68bd509b2eee1ab0e24e6d4f35fpkg/embed.TestBasicClustermysql.procs_privbecause the TN RPC connection127.0.0.1:10020was reset by peer.The PR changes only
pkg/frontend/data_branch.go; the same head passed the complete Ubuntu/x86 UT once, so this is unrelated to PR #26369. The two previous reruns failed in different embedded-cluster consumers with the same timeout/connection-reset family.Latest
mainat2e6877406still starts all CN operators concurrently inpkg/embed.cluster.doStartLocked; each CN reaches bootstrap concurrently, and a transient backend disconnect is converted into a process-wide panic byhandleBootstrapErr. PR #26409 removed one unnecessary full-cluster test but did not changeTestBasicClusteror this startup contract.Focused validation on latest
mainpassedTestBasicCluster5/5 locally in 75.6s, confirming that the failure is load-sensitive. The issue is therefore still present structurally and requires a deterministic stress/fault regression test before changing behavior.gouhongshen commentedon Jul 30, 2026
A root-cause fix is now available in draft PR #26414. It retries the complete bootstrap transaction only after a transient connection error and a durable-state check confirms bootstrap is incomplete; this also handles a lost successful commit response without duplicating initialization.