WritePrepared: fix typo in comments

Summary: Pull Request resolved: https://github.com/facebook/rocksdb/pull/4891

Differential Revision: D13718016

Pulled By: miasantreble

fbshipit-source-id: 90bd372cff453a1c2d104c1cf49731d5dd770c14
main
tom wang 6 years ago committed by Facebook Github Bot
parent dd9eca1c58
commit 73ff15c07b
  1. 4
      utilities/transactions/write_prepared_txn.cc

@ -327,7 +327,7 @@ Status WritePreparedTxn::RollbackInternal() {
const uint64_t NO_REF_LOG = 0; const uint64_t NO_REF_LOG = 0;
uint64_t seq_used = kMaxSequenceNumber; uint64_t seq_used = kMaxSequenceNumber;
const size_t ONE_BATCH = 1; const size_t ONE_BATCH = 1;
// We commit the rolled back prepared batches. ALthough this is // We commit the rolled back prepared batches. Although this is
// counter-intuitive, i) it is safe to do so, since the prepared batches are // counter-intuitive, i) it is safe to do so, since the prepared batches are
// already canceled out by the rollback batch, ii) adding the commit entry to // already canceled out by the rollback batch, ii) adding the commit entry to
// CommitCache will allow us to benefit from the existing mechanism in // CommitCache will allow us to benefit from the existing mechanism in
@ -339,7 +339,7 @@ Status WritePreparedTxn::RollbackInternal() {
// Note: the rollback batch does not need AddPrepared since it is written to // Note: the rollback batch does not need AddPrepared since it is written to
// DB in one shot. min_uncommitted still works since it requires capturing // DB in one shot. min_uncommitted still works since it requires capturing
// data that is written to DB but not yet committed, while // data that is written to DB but not yet committed, while
// the roolback batch commits with PreReleaseCallback. // the rollback batch commits with PreReleaseCallback.
s = db_impl_->WriteImpl(write_options_, &rollback_batch, nullptr, nullptr, s = db_impl_->WriteImpl(write_options_, &rollback_batch, nullptr, nullptr,
NO_REF_LOG, !DISABLE_MEMTABLE, &seq_used, ONE_BATCH, NO_REF_LOG, !DISABLE_MEMTABLE, &seq_used, ONE_BATCH,
do_one_write ? &update_commit_map : nullptr); do_one_write ? &update_commit_map : nullptr);

Loading…
Cancel
Save