rocksdb/include/rocksdb
Maysam Yabandeh 4e3c3d8c6a WritePrepared Txn: duplicate keys
Summary:
With WriteCommitted, when the write batch has duplicate keys, the txn db simply inserts them to the db with different seq numbers and let the db ignore/merge the duplicate values at the read time. With WritePrepared all the entries of the batch are inserted with the same seq number which prevents us from benefiting from this simple solution.

This patch applies a hackish solution to unblock the end-to-end testing. The hack is to be replaced with a proper solution soon. The patch simply detects the duplicate key insertions, and mark the previous one as obsolete. Then before writing to the db it rewrites the batch eliminating the obsolete keys. This would incur a memcpy cost. Furthermore handing duplicate merge would require to do FullMerge instead of simply ignoring the previous value, which is not handled by this patch.
Closes https://github.com/facebook/rocksdb/pull/2969

Differential Revision: D5976337

Pulled By: maysamyabandeh

fbshipit-source-id: 114e65b66f137d8454ff2d1d782b8c05da95f989
2017-10-05 07:41:02 -07:00
..
utilities WritePrepared Txn: duplicate keys 2017-10-05 07:41:02 -07:00
advanced_options.h Remove 'experimental' comment around level_compaction_dynamic_level_bytes option 2017-09-13 15:56:24 -07:00
c.h Make bytes_per_sync and wal_bytes_per_sync mutable 2017-09-27 17:49:45 -07:00
cache.h Revert "comment out unused parameters" 2017-07-21 18:26:26 -07:00
cleanable.h enable PinnableSlice for RowCache 2017-07-17 15:08:30 -07:00
compaction_filter.h Revert "comment out unused parameters" 2017-07-21 18:26:26 -07:00
compaction_job_stats.h Change RocksDB License 2017-07-15 16:11:23 -07:00
comparator.h Replace dynamic_cast<> 2017-07-28 16:27:16 -07:00
convenience.h add VerifyChecksum() to db.h 2017-08-09 15:58:13 -07:00
db_bench_tool.h Change RocksDB License 2017-07-15 16:11:23 -07:00
db_dump_tool.h Change RocksDB License 2017-07-15 16:11:23 -07:00
db.h Extend property map with compaction stats 2017-08-30 15:26:55 -07:00
env_encryption.h Change RocksDB License 2017-07-15 16:11:23 -07:00
env.h Make bytes_per_sync and wal_bytes_per_sync mutable 2017-09-27 17:49:45 -07:00
experimental.h Change RocksDB License 2017-07-15 16:11:23 -07:00
filter_policy.h Fix missing stdlib include required for abort() 2017-08-15 12:32:11 -07:00
flush_block_policy.h Change RocksDB License 2017-07-15 16:11:23 -07:00
iostats_context.h Change RocksDB License 2017-07-15 16:11:23 -07:00
iterator.h Add Iterator::Refresh() 2017-07-24 10:54:37 -07:00
ldb_tool.h Change RocksDB License 2017-07-15 16:11:23 -07:00
listener.h Add ValueType::kTypeBlobIndex 2017-10-03 09:11:23 -07:00
memtablerep.h Revert "comment out unused parameters" 2017-07-21 18:26:26 -07:00
merge_operator.h Introduce conditional merge-operator invocation in point lookups 2017-09-28 15:58:49 -07:00
metadata.h Change RocksDB License 2017-07-15 16:11:23 -07:00
options.h WritePrepared Txn: Advance seq one per batch 2017-09-18 14:45:08 -07:00
perf_context.h perf_context measure user bytes read 2017-08-18 11:43:33 -07:00
perf_level.h Change RocksDB License 2017-07-15 16:11:23 -07:00
persistent_cache.h Change RocksDB License 2017-07-15 16:11:23 -07:00
rate_limiter.h rate limit auto-tuning 2017-10-04 19:15:01 -07:00
slice_transform.h Revert "comment out unused parameters" 2017-07-21 18:26:26 -07:00
slice.h allow nullptr Slice only as sentinel 2017-08-23 10:56:06 -07:00
snapshot.h Change RocksDB License 2017-07-15 16:11:23 -07:00
sst_dump_tool.h Change RocksDB License 2017-07-15 16:11:23 -07:00
sst_file_manager.h Change RocksDB License 2017-07-15 16:11:23 -07:00
sst_file_writer.h Change RocksDB License 2017-07-15 16:11:23 -07:00
statistics.h add counter for deletion dropping optimization 2017-08-19 14:10:08 -07:00
status.h Change RocksDB License 2017-07-15 16:11:23 -07:00
table_properties.h FIFO Compaction with TTL 2017-06-27 17:11:48 -07:00
table.h support disabling checksum in block-based table 2017-08-23 19:40:47 -07:00
thread_status.h Change RocksDB License 2017-07-15 16:11:23 -07:00
threadpool.h Change RocksDB License 2017-07-15 16:11:23 -07:00
transaction_log.h Change RocksDB License 2017-07-15 16:11:23 -07:00
types.h Change RocksDB License 2017-07-15 16:11:23 -07:00
universal_compaction.h Change RocksDB License 2017-07-15 16:11:23 -07:00
version.h Bumping version to 5.8 2017-08-30 14:26:12 -07:00
wal_filter.h Revert "comment out unused parameters" 2017-07-21 18:26:26 -07:00
write_batch_base.h Change RocksDB License 2017-07-15 16:11:23 -07:00
write_batch.h WritePrepared Txn: duplicate keys 2017-10-05 07:41:02 -07:00
write_buffer_manager.h Change RocksDB License 2017-07-15 16:11:23 -07:00