pin L0 filters/indexes for compaction outputs

Summary:
We need to tell the iterator the compaction output file's level so it can apply proper optimizations, like pinning filter and index blocks when user enables `pin_l0_filter_and_index_blocks_in_cache` and the output file's level is zero.
Closes https://github.com/facebook/rocksdb/pull/2949

Differential Revision: D5945597

Pulled By: ajkr

fbshipit-source-id: 2389decf9026ffaa32d45801a77d002529f64a62
main
Andrew Kryczka 7 years ago committed by Facebook Github Bot
parent 283d60761e
commit 821887036e
  1. 3
      db/compaction_job.cc

@ -1122,7 +1122,8 @@ Status CompactionJob::FinishCompactionOutputFile(
nullptr /* range_del_agg */, nullptr,
cfd->internal_stats()->GetFileReadHist(
compact_->compaction->output_level()),
false);
false, nullptr /* arena */, false /* skip_filters */,
compact_->compaction->output_level());
s = iter->status();
if (s.ok() && paranoid_file_checks_) {

Loading…
Cancel
Save