executor: fix data race because of using shared KV requests (#61376)
This is an automated cherry-pick of #61376
What problem does this PR solve?
Issue Number: close #60175
Problem Summary:
What changed and how does it work?
The different coprocessor iterator should run on different KV requests, the share usage can cause data race.
Check List
Tests
- [x] Unit test
- [ ] Integration test
- [ ] Manual test (add detailed scripts or steps below)
- [ ] No need to test
- [ ] I checked and no code files have been changed.
Side effects
- [ ] Performance regression: Consumes more CPU
- [ ] Performance regression: Consumes more Memory
- [ ] Breaking backward compatibility
Documentation
- [ ] Affects user behaviors
- [ ] Contains syntax changes
- [ ] Contains variable changes
- [ ] Contains experimental features
- [ ] Changes MySQL compatibility
Release note
Please refer to Release Notes Language Style Guide to write a quality release note.
None
Codecov Report
Attention: Patch coverage is 80.85106% with 9 lines in your changes missing coverage. Please review.
Please upload report for BASE (
release-8.5@f43a133). Learn more about missing BASE report.
Additional details and impacted files
@@ Coverage Diff @@
## release-8.5 #61416 +/- ##
================================================
Coverage ? 57.2067%
================================================
Files ? 1771
Lines ? 629940
Branches ? 0
================================================
Hits ? 360368
Misses ? 245441
Partials ? 24131
| Flag | Coverage Δ | |
|---|---|---|
| integration | 37.0841% <80.8510%> (?) |
|
| unit | 72.8238% <80.8510%> (?) |
Flags with carried forward coverage won't be shown. Click here to find out more.
| Components | Coverage Δ | |
|---|---|---|
| dumpling | 52.9278% <0.0000%> (?) |
|
| parser | ∅ <0.0000%> (?) |
|
| br | 52.4813% <0.0000%> (?) |
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
- :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
/retest
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: cfzjywxk, zyguan
The full list of commands accepted by this bot can be found here.
The pull request process is described here
- ~~OWNERS~~ [cfzjywxk,zyguan]
- ~~pkg/distsql/OWNERS~~ [cfzjywxk]
Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment
[LGTM Timeline notifier]
Timeline:
/retest
/retest
/retest
/retest
/retest