Merge branch 'master' into columnfamilies
Conflicts: db/db_impl.cc
This commit is contained in:
commit
5693db2a02
@ -2513,8 +2513,7 @@ Status DBImpl::DoCompactionWork(CompactionState* compact,
|
|||||||
// If this is the bottommost level (no files in lower levels)
|
// If this is the bottommost level (no files in lower levels)
|
||||||
// and the earliest snapshot is larger than this seqno
|
// and the earliest snapshot is larger than this seqno
|
||||||
// then we can squash the seqno to zero.
|
// then we can squash the seqno to zero.
|
||||||
if (options_.compaction_style == kCompactionStyleLevel &&
|
if (bottommost_level && ikey.sequence < earliest_snapshot &&
|
||||||
bottommost_level && ikey.sequence < earliest_snapshot &&
|
|
||||||
ikey.type != kTypeMerge) {
|
ikey.type != kTypeMerge) {
|
||||||
assert(ikey.type != kTypeDeletion);
|
assert(ikey.type != kTypeDeletion);
|
||||||
// make a copy because updating in place would cause problems
|
// make a copy because updating in place would cause problems
|
||||||
|
@ -2276,7 +2276,6 @@ Compaction* VersionSet::CompactRange(int input_level, int output_level,
|
|||||||
|
|
||||||
Iterator* VersionSet::MakeInputIterator(Compaction* c) {
|
Iterator* VersionSet::MakeInputIterator(Compaction* c) {
|
||||||
ReadOptions options;
|
ReadOptions options;
|
||||||
options.verify_checksums = options_->paranoid_checks;
|
|
||||||
options.fill_cache = false;
|
options.fill_cache = false;
|
||||||
|
|
||||||
// Level-0 files have to be merged together. For other levels,
|
// Level-0 files have to be merged together. For other levels,
|
||||||
|
@ -693,7 +693,7 @@ enum ReadTier {
|
|||||||
struct ReadOptions {
|
struct ReadOptions {
|
||||||
// If true, all data read from underlying storage will be
|
// If true, all data read from underlying storage will be
|
||||||
// verified against corresponding checksums.
|
// verified against corresponding checksums.
|
||||||
// Default: false
|
// Default: true
|
||||||
bool verify_checksums;
|
bool verify_checksums;
|
||||||
|
|
||||||
// Should the "data block"/"index block"/"filter block" read for this
|
// Should the "data block"/"index block"/"filter block" read for this
|
||||||
@ -734,11 +734,13 @@ struct ReadOptions {
|
|||||||
|
|
||||||
// Specify to create a tailing iterator -- a special iterator that has a
|
// Specify to create a tailing iterator -- a special iterator that has a
|
||||||
// view of the complete database (i.e. it can also be used to read newly
|
// view of the complete database (i.e. it can also be used to read newly
|
||||||
// added data) and is optimized for sequential reads.
|
// added data) and is optimized for sequential reads. It will return records
|
||||||
|
// that were inserted into the database after the creation of the iterator.
|
||||||
|
// Default: false
|
||||||
bool tailing;
|
bool tailing;
|
||||||
|
|
||||||
ReadOptions()
|
ReadOptions()
|
||||||
: verify_checksums(false),
|
: verify_checksums(true),
|
||||||
fill_cache(true),
|
fill_cache(true),
|
||||||
prefix_seek(false),
|
prefix_seek(false),
|
||||||
snapshot(nullptr),
|
snapshot(nullptr),
|
||||||
|
Loading…
Reference in New Issue
Block a user