Restore: refine split code for both compacted sst files and logs (#56917) #64881
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.
This is an automated cherry-pick of #56917
What problem does this PR solve?
Issue Number: ref #56522
This is the first PR split from #54813.
Problem Summary:
Focus on restore compacted sst files
What changed and how does it work?
This PR primarily makes the following adjustments:
Removal of Log Split: The log splitting logic has been removed, simplifying the code structure and making future usage more convenient.
Unified Split Logic: The splitting logic for SST files and log files has been unified, allowing both to share the same logic, reducing code duplication and improving maintainability.
Facilitates Future Extensions: This unified approach makes it easier to extend and modify the handling of SST and log files in the future, enhancing the flexibility of the code.
Overall, these changes lead to a cleaner codebase with clearer logic, laying a solid foundation for future development and maintenance.
Check List
Tests
Side effects
Documentation
Release note
Please refer to Release Notes Language Style Guide to write a quality release note.