Large amount of initial scan tasks affects the lags of normal running changefeeds
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 56
- Forks
- 63
- Avg merge
- 2d 20h
- Merged PRs (30d)
- 34
Description
For example, when a changefeed related to lots of regions start, there are lots of initial(incremental) scan tasks are sent to TiKV. TiKV has got only one task list for the scan tasks. So the task list are full of scan tasks, which needs a long time to consume them all. During the processing, some normal scan tasks from the running changefeeds could be generated caused by Region split/merge/migration. And those normal scan tasks have to wait for a long time, which introduce long lags.
We already done some optimizations, including
- https://github.com/pingcap/ticdc/pull/1219 During the starting of a changefeed, split the tasks into small batches, and only send one batch to TiKV at a time.
TODO:
- Run more tests to learn the current situation.
- More optimizations to mitigate the issue if required.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing PR #1219 and the described changefeed startup batching behavior. Run tests or experiments that measure normal scan-task lag while a large initial scan is active, then determine whether further mitigation is required. The issue names no files or tests, so the relevant implementation and validation locations will need to be identified first.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- distributed-systems, performance
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100