Add ColumnDB projected blob read prototype#14847
Draft
xingbowang wants to merge 1 commit into
Draft
Conversation
Summary: Add a `ColumnDB` stackable DB prototype in `fbcode/internal_repo_rocksdb/repo` for projected reads from blob-backed wide-column entities. `ColumnDB` reads the inline schema column, invokes a caller-provided translate callback to map requested columns to blob byte ranges, coalesces adjacent ranges, and calls `DBImpl::MultiGetBlobRanges` to issue partial blob-file reads. This also adds lazy V2 wide-column blob-index exposure for callers that explicitly request raw blob indexes, partial blob-range read plumbing through `DBImpl` and `Version`, external blob-file support in `SstFileWriter` and external-file ingestion, and `db_bench` workloads plus `tools/run_column_db_bench.sh` for full-read versus projected-read comparison. Benchmark result from the prior direct-IO host run: | value_size | projected | stride | full_read_ops | column_read_ops | read_speedup | full_read_cpu_s | column_read_cpu_s | read_cpu_s_ratio | full_read_fs_inputs | column_read_fs_inputs | read_fs_input_ratio | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | 102400 | 5 | 1 | 32401 | 44437 | 1.371 | 40.660 | 25.480 | 0.627 | 172803016 | 26247264 | 0.152 | | 102400 | 5 | 97 | 32667 | 31848 | 0.975 | 40.670 | 39.480 | 0.971 | 172803016 | 51852160 | 0.300 | | 102400 | 10 | 1 | 32659 | 44076 | 1.350 | 40.490 | 25.960 | 0.641 | 172803016 | 27046424 | 0.157 | | 102400 | 10 | 97 | 32297 | 27431 | 0.849 | 42.310 | 60.310 | 1.425 | 172803016 | 84649256 | 0.490 | | 1048576 | 5 | 1 | 7802 | 41900 | 5.370 | 225.720 | 28.860 | 0.128 | 1651236952 | 33620536 | 0.020 | | 1048576 | 5 | 97 | 7793 | 37065 | 4.756 | 226.570 | 39.910 | 0.176 | 1651236952 | 59209224 | 0.036 | | 1048576 | 10 | 1 | 7795 | 41071 | 5.269 | 224.660 | 28.500 | 0.127 | 1651236952 | 41813008 | 0.025 | | 1048576 | 10 | 97 | 7806 | 31307 | 4.011 | 223.940 | 62.210 | 0.278 | 1651236952 | 99409896 | 0.060 | Differential Revision: D108213380
|
@xingbowang has exported this pull request. If you are a Meta employee, you can view the originating Diff in D108213380. |
|
| Check | Count |
|---|---|
performance-no-automatic-move |
1 |
| Total | 1 |
Details
table/sst_file_writer.cc (1 warning(s))
table/sst_file_writer.cc:277:14: warning: constness of 's' prevents automatic move [performance-no-automatic-move]
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.
Summary:
Add a
ColumnDBstackable DB prototype infbcode/internal_repo_rocksdb/repofor projected reads from blob-backed wide-column entities.ColumnDBreads the inline schema column, invokes a caller-provided translate callback to map requested columns to blob byte ranges, coalesces adjacent ranges, and callsDBImpl::MultiGetBlobRangesto issue partial blob-file reads.This also adds lazy V2 wide-column blob-index exposure for callers that explicitly request raw blob indexes, partial blob-range read plumbing through
DBImplandVersion, external blob-file support inSstFileWriterand external-file ingestion, anddb_benchworkloads plustools/run_column_db_bench.shfor full-read versus projected-read comparison.Benchmark result from the prior direct-IO host run:
Differential Revision: D108213380