feat(mito): support write cache for index file#3144
Merged
killme2008 merged 4 commits intoGreptimeTeam:mainfrom Jan 12, 2024
Merged
feat(mito): support write cache for index file#3144killme2008 merged 4 commits intoGreptimeTeam:mainfrom
killme2008 merged 4 commits intoGreptimeTeam:mainfrom
Conversation
f70325f to
782724b
Compare
Signed-off-by: Zhenchi <zhongzc_arch@outlook.com>
782724b to
37ba7e0
Compare
7 tasks
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #3144 +/- ##
==========================================
- Coverage 85.41% 84.97% -0.45%
==========================================
Files 823 823
Lines 134797 134917 +120
==========================================
- Hits 115138 114640 -498
- Misses 19659 20277 +618 |
22 tasks
evenyag
reviewed
Jan 11, 2024
Signed-off-by: Zhenchi <zhongzc_arch@outlook.com>
Signed-off-by: Zhenchi <zhongzc_arch@outlook.com>
evenyag
approved these changes
Jan 11, 2024
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
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.
I hereby agree to the terms of the GreptimeDB CLA
What's changed and what's your intention?
Regarding the upcoming SST Inverted Index Creator for the Parquet Writer, its implementation unavoidably has to be coupled with
ParquetWriter::write_all(for which I am very sorry, and if there's a better solution, I am open to suggestions). Consequently, depending on theWriteOptionsconfiguration,ParquetWriter::write_allwill generate either a Parquet data file or a Parquet data file plus a Puffin index file.This breaks some assumptions, for instance, with delete: the deletion of index files needs to be considered; with disk usage: the size of the index files needs to be taken into account. The recently added Write Cache feature also assumes that
ParquetWriter::write_allonly produces a single Parquet data file, an assumption that is unfortunately no longer correct.This PR is to fix the soon-to-be outdated assumptions of the Write Cache:
FileTypeto the IndexKey in FileCache to indicate that the WriteCache contains not only Parquet files but also Puffin files.write_and_upload_sstmethod upload Puffin files as well (if generated).SstIndexApplierto benefit from local cache acceleration.Checklist
Refer to a related PR or issue link (optional)
#2705 #2965