rocksdb/db/compaction
Jay Huh 57a8e69d4e Include TableProperties in the CompactionServiceResult (#13089)
Summary:
In Remote Compactions, the primary host receives the serialized compaction result from the remote worker and deserializes it to build the output. Unlike Local Compactions, where table properties are built by TableBuilder, in Remote Compactions, these properties were not included in the serialized compaction result. This was likely done intentionally since the table properties are already available in the SST files.

Because TableProperties are not populated as part of CompactionOutputs for remote compactions, we were unable to log the table properties in OnCompactionComplete and use them for verification. We are adding the TableProperties as part of the CompactionServiceOutputFile in this PR. By including the TableProperties in the serialized compaction result, the primary host will be able to access them and verify that they match the values read from the actual SST files.

We are also adding the populating `format_version` in table_properties of in TableBuilder.  This has not been a big issue because the `format_version` is written to the SST files directly from `TableOptions.format_version`. When loaded from the SST files, it's populated directly by reading from the MetaBlock. This info has only been missing in the TableBuilder's Rep.props.

Pull Request resolved: https://github.com/facebook/rocksdb/pull/13089

Test Plan:
```
./compaction_job_test
```
```
./compaction_service_test
```

Reviewed By: pdillinger

Differential Revision: D64878740

Pulled By: jaykorean

fbshipit-source-id: b6f2fdce851e6477ecb4dd5a87cdc62e176b746b
2024-10-25 13:13:12 -07:00
..
clipping_iterator.h
clipping_iterator_test.cc
compaction.cc Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction.h Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_iteration_stats.h
compaction_iterator.cc
compaction_iterator.h Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_iterator_test.cc
compaction_job.cc Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_job.h Include TableProperties in the CompactionServiceResult (#13089) 2024-10-25 13:13:12 -07:00
compaction_job_stats_test.cc
compaction_job_test.cc Include TableProperties in the CompactionServiceResult (#13089) 2024-10-25 13:13:12 -07:00
compaction_outputs.cc
compaction_outputs.h Include TableProperties in the CompactionServiceResult (#13089) 2024-10-25 13:13:12 -07:00
compaction_picker.cc Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_picker.h Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_picker_fifo.cc Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_picker_fifo.h Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_picker_level.cc Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_picker_level.h Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_picker_test.cc Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_picker_universal.cc Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_picker_universal.h Optimize compaction for standalone range deletion files (#13078) 2024-10-25 09:32:14 -07:00
compaction_service_job.cc Include TableProperties in the CompactionServiceResult (#13089) 2024-10-25 13:13:12 -07:00
compaction_service_test.cc
compaction_state.cc
compaction_state.h
file_pri.h
sst_partitioner.cc
subcompaction_state.cc
subcompaction_state.h
tiered_compaction_test.cc