-
Notifications
You must be signed in to change notification settings - Fork 3.7k
branch-3.1: [enhance](memtable) skip memtable in queue to speed up cancel #53481 #54122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
morrySnow
merged 1 commit into
apache:branch-3.1
from
sollhui:3.1_speed_up_memtable_cancel
Jul 31, 2025
Merged
branch-3.1: [enhance](memtable) skip memtable in queue to speed up cancel #53481 #54122
morrySnow
merged 1 commit into
apache:branch-3.1
from
sollhui:3.1_speed_up_memtable_cancel
Jul 31, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…#53481) At present, if load/update/delete is cancelled, it needs to wait for all submitted memtable task of related `FlushToken` to be completed, included: - flush task wait in thread pool queue - ongoing flushing task It is not need wait flush task still in the thread pool queue which can speed up cancel load/update/delete. <img width="1686" height="660" alt="image" src="https://github.com/user-attachments/assets/8eb8f43c-10d9-4b95-8933-d341f12857ce" /> For example, cancel load1. The current logic is to wait for all submit task(queue+flushing), but for those in the queue, they have to wait for all the previously queued ones to complete before it's their turn. Skip memtable in queue can speed up cancel for: - If there are still memtables for load2 and load3 in front of load1 memtable, cancel block until other load memtable been flushed. - Under more extreme conditions, the submit task count may add when wait submit task finish.
Contributor
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
Contributor
Author
|
run buildall |
TPC-H: Total hot run time: 32757 ms |
TPC-DS: Total hot run time: 196718 ms |
ClickBench: Total hot run time: 28.92 s |
morrySnow
approved these changes
Jul 31, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
pick #53481
At present, if load/update/delete is cancelled, it needs to wait for all submitted memtable task of related
FlushTokento be completed, included:It is not need wait flush task still in the thread pool queue which can speed up cancel load/update/delete.
For example, cancel load1. The current logic is to wait for all submit task(queue+flushing), but for those in the queue, they have to wait for all the previously queued ones to complete before it's their turn. Skip memtable in queue can speed up cancel for:
If there are still memtables for load2 and load3 in front of load1 memtable, cancel block until other load memtable been flushed.
Under more extreme conditions, the submit task count may add when wait submit task finish.
What problem does this PR solve?
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
Release note
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)