Make it possible to enable periodic compactions for BlobDB (#6172)

Summary:
Periodic compactions ensure that even SSTs that do not get picked up
otherwise eventually go through compaction; used in conjunction with
BlobDB's garbage collection, they enable BlobDB to reclaim space when
old blob files are used by such straggling SSTs.
Pull Request resolved: https://github.com/facebook/rocksdb/pull/6172

Test Plan: Ran `make check` and used the BlobDB mode of `db_bench`.

Differential Revision: D19045045

Pulled By: ltamasi

fbshipit-source-id: 04636ecc4b6cfe8d495bf656faa65d54a5eb1a93
main
Levi Tamasi 5 years ago committed by Facebook Github Bot
parent afa2420c2b
commit 0d2172f128
  1. 4
      utilities/blob_db/blob_db_impl.cc

@ -148,10 +148,6 @@ Status BlobDBImpl::Open(std::vector<ColumnFamilyHandle*>* handles) {
"Garbage collection cutoff must be in the interval [0.0, 1.0]");
}
// BlobDB does not support Periodic Compactions. So disable periodic
// compactions irrespective of the user set value.
cf_options_.periodic_compaction_seconds = 0;
// Temporarily disable compactions in the base DB during open; save the user
// defined value beforehand so we can restore it once BlobDB is initialized.
// Note: this is only needed if garbage collection is enabled.

Loading…
Cancel
Save