rocksdb/utilities/transactions
Maysam Yabandeh 52aab66424 WritePrepared Txn: enable TryAgain for duplicates at the end of the batch
Summary:
The WriteBatch::Iterate will try with a larger sequence number if the memtable reports a duplicate. This status is specified with TryAgain status. So far the assumption was that the last entry in the batch will never return TryAgain, which is correct when WAL is created via WritePrepared since it always appends a batch separator if a natural one does not exist. However when reading a WAL generated by WriteCommitted this batch separator might  not exist. Although WritePrepared is not supposed to be able to read the WAL generated by WriteCommitted we should avoid confusing scenarios in which the behavior becomes unpredictable. The path fixes that by allowing TryAgain even for the last entry of the write batch.
Closes https://github.com/facebook/rocksdb/pull/3747

Differential Revision: D7708391

Pulled By: maysamyabandeh

fbshipit-source-id: bfaddaa9b14a4cdaff6977f6f63c789a6ab1ee0d
2018-05-08 14:13:12 -07:00
..
optimistic_transaction_db_impl.cc Refactor PessimisticTransaction 2017-08-07 16:12:29 -07:00
optimistic_transaction_db_impl.h Change RocksDB License 2017-07-15 16:11:23 -07:00
optimistic_transaction_test.cc Change RocksDB License 2017-07-15 16:11:23 -07:00
optimistic_transaction.cc Update WritePrepared with the pseudo code 2017-08-16 16:57:47 -07:00
optimistic_transaction.h Update WritePrepared with the pseudo code 2017-08-16 16:57:47 -07:00
pessimistic_transaction_db.cc Fix some typos in comments and docs. 2018-03-08 10:27:25 -08:00
pessimistic_transaction_db.h WritePrepared Txn: smallest_prepare optimization 2018-04-12 13:55:36 -07:00
pessimistic_transaction.cc Skip deleted WALs during recovery 2018-05-08 14:10:18 -07:00
pessimistic_transaction.h WritePrepared Txn: Duplicate Keys, Txn Part 2018-02-05 18:43:24 -08:00
snapshot_checker.cc WritePrepared Txn: Move DB class to its own file 2017-11-02 11:14:30 -07:00
transaction_base.cc Suppress unused warnings 2018-02-02 12:27:07 -08:00
transaction_base.h WritePrepared Txn: smallest_prepare optimization 2018-04-12 13:55:36 -07:00
transaction_db_mutex_impl.cc Change RocksDB License 2017-07-15 16:11:23 -07:00
transaction_db_mutex_impl.h Change RocksDB License 2017-07-15 16:11:23 -07:00
transaction_lock_mgr.cc save redundant key lookup in map of locked keys 2018-02-20 17:44:44 -08:00
transaction_lock_mgr.h Added mechanism to track deadlock chain 2017-08-17 18:56:21 -07:00
transaction_test.cc Skip deleted WALs during recovery 2018-05-08 14:10:18 -07:00
transaction_test.h WritePrepared Txn: enable TryAgain for duplicates at the end of the batch 2018-05-08 14:13:12 -07:00
transaction_util.cc WritePrepared Txn: ValidateSnapshot 2017-11-01 19:11:09 -07:00
transaction_util.h WritePrepared Txn: ValidateSnapshot 2017-11-01 19:11:09 -07:00
write_prepared_transaction_test.cc WritePrepared Txn: fix smallest_prep atomicity issue 2018-04-12 14:00:25 -07:00
write_prepared_txn_db.cc WritePrepared Txn: fix smallest_prep atomicity issue 2018-04-12 14:00:25 -07:00
write_prepared_txn_db.h WritePrepared Txn: fix smallest_prep atomicity issue 2018-04-12 14:00:25 -07:00
write_prepared_txn.cc WritePrepared Txn: rollback_merge_operands hack 2018-04-12 14:01:54 -07:00
write_prepared_txn.h WritePrepared Txn: smallest_prepare optimization 2018-04-12 13:55:36 -07:00