Skip to content
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

chore: try to fast purge(gc) #8153

Merged
merged 13 commits into from
Oct 13, 2022
Merged

chore: try to fast purge(gc) #8153

merged 13 commits into from
Oct 13, 2022

Conversation

BohuTANG
Copy link
Member

@BohuTANG BohuTANG commented Oct 12, 2022

I hereby agree to the terms of the CLA available at: https://databend.rs/dev/policies/cla/

Summary

Try to fast optimize table xx purge

  • Read snapshot files in parallel
  • Read segment files in parallel
  • Remove block files in parallel
  • Remove segment files in parallel
  • Remove snapshot files in parallel

30000+ snapshot files:

mysql> optimize table t7861 purge;
Connection id:    9
Current database: db7861

Query OK, 0 rows affected (8 min 16.69 sec)

Fixes #issue

@vercel
Copy link

vercel bot commented Oct 12, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Updated
databend ⬜️ Ignored (Inspect) Oct 13, 2022 at 1:21AM (UTC)

@mergify mergify bot added the pr-chore this PR only has small changes that no need to record, like coding styles. label Oct 12, 2022
@BohuTANG BohuTANG changed the title chore: try to fast compact(gc) chore: try to fast purge(gc) Oct 12, 2022
@BohuTANG BohuTANG requested a review from dantengsky October 12, 2022 11:08
@BohuTANG
Copy link
Member Author

Some issues with

truncate table t2 purge;

Copy link
Member

@dantengsky dantengsky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@BohuTANG BohuTANG marked this pull request as ready for review October 13, 2022 01:35
Copy link
Member

@drmingdrmer drmingdrmer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr-chore this PR only has small changes that no need to record, like coding styles.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants