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: make vacuum temp files batch #15430

Closed

Conversation

BohuTANG
Copy link
Member

@BohuTANG BohuTANG commented May 8, 2024

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

Summary

Batch process the VACUUM TEMPORARY FILES operation. For every 10,000 files, perform a removal in parallel batches.

  • Fixes #[Link the issue here]

Tests

Type of change

  • Bug Fix (non-breaking change which fixes an issue)
  • New Feature (non-breaking change which adds functionality)
  • Breaking Change (fix or feature that could cause existing functionality not to work as expected)
  • Documentation Update
  • Refactoring
  • Performance Improvement
  • Other (please describe):

This change is Reviewable

@github-actions github-actions bot added the pr-chore this PR only has small changes that no need to record, like coding styles. label May 8, 2024
@BohuTANG BohuTANG force-pushed the dev-vacuum-temp-file-paral-2 branch from add79ba to 3eea325 Compare May 8, 2024 03:49
@BohuTANG BohuTANG requested a review from zhang2014 May 8, 2024 03:50
@BohuTANG BohuTANG marked this pull request as ready for review May 8, 2024 03:52
remove_temp_files_name.push(de.name().to_string());
}

// If the batch size is reached, remove the files in batch.
if expired_files.len() >= BATCH_SIZE {
Copy link
Member

Choose a reason for hiding this comment

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

maybe operator.remove_via is better?

Copy link
Member Author

Choose a reason for hiding this comment

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

Will have a check:)

@BohuTANG
Copy link
Member Author

BohuTANG commented May 8, 2024

Move to #15434

@BohuTANG BohuTANG closed this May 8, 2024
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.

2 participants