diff --git a/db/memtable.cc b/db/memtable.cc index 989a526c8..ec6cd81be 100644 --- a/db/memtable.cc +++ b/db/memtable.cc @@ -788,6 +788,7 @@ void MemTable::Update(SequenceNumber seq, assert((unsigned)((p + value.size()) - entry) == (unsigned)(VarintLength(key_length) + key_length + VarintLength(value.size()) + value.size())); + RecordTick(moptions_.statistics, NUMBER_KEYS_UPDATED); return; } } diff --git a/db/write_batch.cc b/db/write_batch.cc index 39d18c694..18475e944 100644 --- a/db/write_batch.cc +++ b/db/write_batch.cc @@ -1034,7 +1034,6 @@ class MemTableInserter : public WriteBatch::Handler { } else if (moptions->inplace_callback == nullptr) { assert(!concurrent_memtable_writes_); mem->Update(sequence_, key, value); - RecordTick(moptions->statistics, NUMBER_KEYS_UPDATED); } else { assert(!concurrent_memtable_writes_); if (mem->UpdateCallback(sequence_, key, value)) {