diff options
author | Benety Goh <benety@mongodb.com> | 2022-11-15 16:31:02 -0500 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2022-11-15 22:41:59 +0000 |
commit | 819c3c931e4a120342d01b8eb5cbc4a189e29e87 (patch) | |
tree | 89881a3fc4f5d0c61326757b3f56db4773fd0798 /src/mongo/db/op_observer/op_observer_impl_test.cpp | |
parent | 6bb979af9a37a1e4523b7553e51b9c02129a973a (diff) | |
download | mongo-819c3c931e4a120342d01b8eb5cbc4a189e29e87.tar.gz |
SERVER-71210 OpObserver::onTransactionPrepare() accepts const statements and applyOps info
Diffstat (limited to 'src/mongo/db/op_observer/op_observer_impl_test.cpp')
-rw-r--r-- | src/mongo/db/op_observer/op_observer_impl_test.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mongo/db/op_observer/op_observer_impl_test.cpp b/src/mongo/db/op_observer/op_observer_impl_test.cpp index 008fa8a4095..fe7ff8950e3 100644 --- a/src/mongo/db/op_observer/op_observer_impl_test.cpp +++ b/src/mongo/db/op_observer/op_observer_impl_test.cpp @@ -1148,10 +1148,12 @@ protected: auto applyOpsAssignment = opObserver().preTransactionPrepare(opCtx(), reservedSlots, currentTime, txnOps); opCtx()->recoveryUnit()->setPrepareTimestamp(prepareOpTime.getTimestamp()); + const auto& statements = *(txnOps->getMutableOperationsForOpObserver()); + ASSERT(applyOpsAssignment); opObserver().onTransactionPrepare(opCtx(), reservedSlots, - txnOps->getMutableOperationsForOpObserver(), - applyOpsAssignment.get(), + statements, + *applyOpsAssignment, numberOfPrePostImagesToWrite, currentTime); } |