test: stabilize flaky TestTiFlashAvailableAfterAddPartition#69371
test: stabilize flaky TestTiFlashAvailableAfterAddPartition#69371flaky-claw wants to merge 1 commit into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughIn ChangesFlaky test fix: TiFlash poll teardown
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
What problem does this PR solve?
Issue Number: close #68208
Problem Summary:
Flaky test
TestTiFlashAvailableAfterAddPartitioninpkg/ddl/tests/tiflashintermittently fails, so this PR stabilizes that path.What changed and how does it work?
Root Cause
Test-owned mock TiFlash teardown could race with still-enabled background TiFlash polling, causing a connection-refused panic after the test’s intended assertions.
Fix
Disabling TiFlash polling after the test verifies availability prevents a background poll from touching the mock server during teardown.
Verification
Spec:
pkg/ddl/tests/tiflash :: TestTiFlashAvailableAfterAddPartitiontidb.issue_scoped.v2BASELINE_ONLYWRAPPED_GO_TEST./tools/check/failpoint-go-test.shintest, deadlockbaseline_onlyObserved result:
timing_repro passed.
Gate checklist:
Commands:
./tools/check/failpoint-go-test.sh pkg/ddl/tests/tiflash -run '^TestTiFlashAvailableAfterAddPartition$' -count=1Check List
Tests
Side effects
Documentation
Release note
Please refer to Release Notes Language Style Guide to write a quality release note.
Fixes #68208
Summary by CodeRabbit