mirror of https://github.com/facebook/rocksdb.git
f34782a67d
Summary: The earlier code used two conflicting definitions for the number of input records going into a compaction, one based on the `rocksdb.num.entries` table property and one based on `CompactionIterationStats`. The first one is correct and in line with how output records are counted, while the second one incorrectly ignores input records in various cases when the `CompactionIterator` advances or reseeks the input iterator (this can happen, amongst other cases, when dealing with `SingleDelete`s, regular `Delete`s, `Merge`s, and compaction filters). This can result in the code undercounting the input records and computing an incorrect value for "records dropped" during the compaction. The patch fixes this by switching over to the correct (table property based) input record count for "records dropped". Pull Request resolved: https://github.com/facebook/rocksdb/pull/6325 Test Plan: Tested using `make check` and `db_bench`. Differential Revision: D19525491 Pulled By: ltamasi fbshipit-source-id: 4340b0b2f41546db8e356db70ca02199e48fa636 |
||
---|---|---|
.. | ||
compaction.cc | ||
compaction.h | ||
compaction_iteration_stats.h | ||
compaction_iterator.cc | ||
compaction_iterator.h | ||
compaction_iterator_test.cc | ||
compaction_job.cc | ||
compaction_job.h | ||
compaction_job_stats_test.cc | ||
compaction_job_test.cc | ||
compaction_picker.cc | ||
compaction_picker.h | ||
compaction_picker_fifo.cc | ||
compaction_picker_fifo.h | ||
compaction_picker_level.cc | ||
compaction_picker_level.h | ||
compaction_picker_test.cc | ||
compaction_picker_universal.cc | ||
compaction_picker_universal.h |