FastRestore:Move comment to func definition
Resolve review comments.
This commit is contained in:
parent
27c7ef09a3
commit
eb67886b75
|
@ -641,6 +641,7 @@ const KeyRangeRef restoreApplierKeys(LiteralStringRef("\xff\x02/restoreApplier/"
|
|||
const KeyRef restoreApplierTxnValue = LiteralStringRef("1");
|
||||
|
||||
// restoreApplierKeys: track atomic transaction progress to ensure applying atomicOp exactly once
|
||||
// Version integer must be BigEndian to maintain ordering in lexical order
|
||||
const Key restoreApplierKeyFor(UID const& applierID, Version version) {
|
||||
BinaryWriter wr(Unversioned());
|
||||
wr.serializeBytes(restoreApplierKeys.begin);
|
||||
|
|
|
@ -277,8 +277,8 @@ ACTOR Future<Void> applyToDB(Reference<RestoreApplierData> self, Database cx) {
|
|||
tr->reset();
|
||||
tr->setOption(FDBTransactionOptions::ACCESS_SYSTEM_KEYS);
|
||||
tr->setOption(FDBTransactionOptions::LOCK_AWARE);
|
||||
Key begin = restoreApplierKeyFor(
|
||||
self->id(), bigEndian64(0)); // Integer must be BigEndian to maintain ordering in lexical order
|
||||
// Version integer must be BigEndian to maintain ordering in lexical order
|
||||
Key begin = restoreApplierKeyFor(self->id(), bigEndian64(0));
|
||||
Key end = restoreApplierKeyFor(self->id(), bigEndian64(std::numeric_limits<int64_t>::max()));
|
||||
Standalone<RangeResultRef> txnIds = wait(tr->getRange(KeyRangeRef(begin, end), CLIENT_KNOBS->TOO_MANY));
|
||||
if (txnIds.size() > 0) {
|
||||
|
|
Loading…
Reference in New Issue