mirror of
https://github.com/apple/foundationdb.git
synced 2025-06-01 10:45:56 +08:00
Move trace event after transaction commit
This commit is contained in:
parent
2bbc6d68ba
commit
a004e091df
@ -82,13 +82,13 @@ ACTOR Future<MoveKeysLock> takeMoveKeysLock( Database cx, UID ddId ) {
|
||||
lock.prevWrite = readVal.present() ? BinaryReader::fromStringRef<UID>(readVal.get(), Unversioned()) : UID();
|
||||
}
|
||||
lock.myOwner = deterministicRandom()->randomUniqueID();
|
||||
tr.set(moveKeysLockOwnerKey, BinaryWriter::toValue(lock.myOwner, Unversioned()));
|
||||
wait(tr.commit());
|
||||
TraceEvent("TakeMoveKeysLockTransaction", ddId)
|
||||
.detail("TransactionUID", txnId)
|
||||
.detail("PrevOwner", lock.prevOwner.toString())
|
||||
.detail("PrevWrite", lock.prevWrite.toString())
|
||||
.detail("MyOwner", lock.myOwner.toString());
|
||||
tr.set(moveKeysLockOwnerKey, BinaryWriter::toValue(lock.myOwner, Unversioned()));
|
||||
wait(tr.commit());
|
||||
return lock;
|
||||
} catch (Error &e){
|
||||
wait(tr.onError(e));
|
||||
|
Loading…
x
Reference in New Issue
Block a user