summaryrefslogtreecommitdiff
path: root/src/mongo/db/repl
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/repl')
-rw-r--r--src/mongo/db/repl/oplog_applier_impl_test.cpp7
-rw-r--r--src/mongo/db/repl/oplog_applier_impl_test_fixture.cpp6
-rw-r--r--src/mongo/db/repl/replication_recovery_test.cpp7
-rw-r--r--src/mongo/db/repl/rollback_test_fixture.cpp6
-rw-r--r--src/mongo/db/repl/storage_timestamp_test.cpp7
-rw-r--r--src/mongo/db/repl/tenant_oplog_applier_test.cpp6
6 files changed, 30 insertions, 9 deletions
diff --git a/src/mongo/db/repl/oplog_applier_impl_test.cpp b/src/mongo/db/repl/oplog_applier_impl_test.cpp
index 85fafe1c36f..b312f37f048 100644
--- a/src/mongo/db/repl/oplog_applier_impl_test.cpp
+++ b/src/mongo/db/repl/oplog_applier_impl_test.cpp
@@ -67,6 +67,7 @@
#include "mongo/db/session/session_catalog_mongod.h"
#include "mongo/db/session/session_txn_record_gen.h"
#include "mongo/db/stats/counters.h"
+#include "mongo/db/transaction/session_catalog_mongod_transaction_interface_impl.h"
#include "mongo/db/transaction/transaction_participant_gen.h"
#include "mongo/db/update/update_oplog_entry_serialization.h"
#include "mongo/idl/server_parameter_test_util.h"
@@ -2688,8 +2689,10 @@ public:
// secondary index creation does not. We use an UnreplicatedWritesBlock to avoid
// timestamping any of the catalog setup.
repl::UnreplicatedWritesBlock noRep(_opCtx.get());
- MongoDSessionCatalog::set(_opCtx->getServiceContext(),
- std::make_unique<MongoDSessionCatalog>());
+ MongoDSessionCatalog::set(
+ _opCtx->getServiceContext(),
+ std::make_unique<MongoDSessionCatalog>(
+ std::make_unique<MongoDSessionCatalogTransactionInterfaceImpl>()));
auto mongoDSessionCatalog = MongoDSessionCatalog::get(_opCtx.get());
mongoDSessionCatalog->onStepUp(_opCtx.get());
diff --git a/src/mongo/db/repl/oplog_applier_impl_test_fixture.cpp b/src/mongo/db/repl/oplog_applier_impl_test_fixture.cpp
index 76750e8c790..0144dd48887 100644
--- a/src/mongo/db/repl/oplog_applier_impl_test_fixture.cpp
+++ b/src/mongo/db/repl/oplog_applier_impl_test_fixture.cpp
@@ -47,6 +47,7 @@
#include "mongo/db/repl/storage_interface.h"
#include "mongo/db/repl/storage_interface_impl.h"
#include "mongo/db/session/session_catalog_mongod.h"
+#include "mongo/db/transaction/session_catalog_mongod_transaction_interface_impl.h"
#include "mongo/db/vector_clock_mutable.h"
namespace mongo {
@@ -160,7 +161,10 @@ void OplogApplierImplTest::setUp() {
StorageInterface::set(serviceContext, std::make_unique<StorageInterfaceImpl>());
- MongoDSessionCatalog::set(serviceContext, std::make_unique<MongoDSessionCatalog>());
+ MongoDSessionCatalog::set(
+ serviceContext,
+ std::make_unique<MongoDSessionCatalog>(
+ std::make_unique<MongoDSessionCatalogTransactionInterfaceImpl>()));
DropPendingCollectionReaper::set(
serviceContext, std::make_unique<DropPendingCollectionReaper>(getStorageInterface()));
diff --git a/src/mongo/db/repl/replication_recovery_test.cpp b/src/mongo/db/repl/replication_recovery_test.cpp
index fcaef636ac7..c6ddd443124 100644
--- a/src/mongo/db/repl/replication_recovery_test.cpp
+++ b/src/mongo/db/repl/replication_recovery_test.cpp
@@ -50,6 +50,7 @@
#include "mongo/db/storage/durable_history_pin.h"
#include "mongo/db/storage/storage_options.h"
#include "mongo/db/storage/storage_parameters_gen.h"
+#include "mongo/db/transaction/session_catalog_mongod_transaction_interface_impl.h"
#include "mongo/db/transaction/transaction_participant.h"
#include "mongo/db/update/update_oplog_entry_serialization.h"
#include "mongo/unittest/death_test.h"
@@ -204,8 +205,10 @@ private:
ASSERT_OK(_storageInterface->createCollection(
getOperationContext(), testNs, generateOptionsWithUuid()));
- MongoDSessionCatalog::set(_opCtx->getServiceContext(),
- std::make_unique<MongoDSessionCatalog>());
+ MongoDSessionCatalog::set(
+ _opCtx->getServiceContext(),
+ std::make_unique<MongoDSessionCatalog>(
+ std::make_unique<MongoDSessionCatalogTransactionInterfaceImpl>()));
auto mongoDSessionCatalog = MongoDSessionCatalog::get(_opCtx.get());
mongoDSessionCatalog->onStepUp(_opCtx.get());
diff --git a/src/mongo/db/repl/rollback_test_fixture.cpp b/src/mongo/db/repl/rollback_test_fixture.cpp
index e98ab9ca641..96b48365220 100644
--- a/src/mongo/db/repl/rollback_test_fixture.cpp
+++ b/src/mongo/db/repl/rollback_test_fixture.cpp
@@ -46,6 +46,7 @@
#include "mongo/db/repl/replication_recovery.h"
#include "mongo/db/repl/rs_rollback.h"
#include "mongo/db/session/session_catalog_mongod.h"
+#include "mongo/db/transaction/session_catalog_mongod_transaction_interface_impl.h"
#include "mongo/unittest/log_test.h"
#include "mongo/util/str.h"
@@ -108,7 +109,10 @@ void RollbackTest::setUp() {
_replicationProcess->getConsistencyMarkers()->setMinValid(_opCtx.get(), OpTime{});
_replicationProcess->initializeRollbackID(_opCtx.get()).transitional_ignore();
- MongoDSessionCatalog::set(serviceContext, std::make_unique<MongoDSessionCatalog>());
+ MongoDSessionCatalog::set(
+ serviceContext,
+ std::make_unique<MongoDSessionCatalog>(
+ std::make_unique<MongoDSessionCatalogTransactionInterfaceImpl>()));
auto observerRegistry = checked_cast<OpObserverRegistry*>(serviceContext->getOpObserver());
observerRegistry->addObserver(std::make_unique<RollbackTestOpObserver>());
diff --git a/src/mongo/db/repl/storage_timestamp_test.cpp b/src/mongo/db/repl/storage_timestamp_test.cpp
index 73fdc89ac88..50a4f0ac7d3 100644
--- a/src/mongo/db/repl/storage_timestamp_test.cpp
+++ b/src/mongo/db/repl/storage_timestamp_test.cpp
@@ -81,6 +81,7 @@
#include "mongo/db/session/session_catalog_mongod.h"
#include "mongo/db/storage/snapshot_manager.h"
#include "mongo/db/storage/storage_engine_impl.h"
+#include "mongo/db/transaction/session_catalog_mongod_transaction_interface_impl.h"
#include "mongo/db/transaction/transaction_participant.h"
#include "mongo/db/transaction/transaction_participant_gen.h"
#include "mongo/db/update/update_oplog_entry_serialization.h"
@@ -289,8 +290,10 @@ public:
cc().getServiceContext(),
std::unique_ptr<repl::ReplicationProcess>(replicationProcess));
- MongoDSessionCatalog::set(_opCtx->getServiceContext(),
- std::make_unique<MongoDSessionCatalog>());
+ MongoDSessionCatalog::set(
+ _opCtx->getServiceContext(),
+ std::make_unique<MongoDSessionCatalog>(
+ std::make_unique<MongoDSessionCatalogTransactionInterfaceImpl>()));
_consistencyMarkers =
repl::ReplicationProcess::get(cc().getServiceContext())->getConsistencyMarkers();
diff --git a/src/mongo/db/repl/tenant_oplog_applier_test.cpp b/src/mongo/db/repl/tenant_oplog_applier_test.cpp
index 04d8005f23a..9905fc65c33 100644
--- a/src/mongo/db/repl/tenant_oplog_applier_test.cpp
+++ b/src/mongo/db/repl/tenant_oplog_applier_test.cpp
@@ -50,6 +50,7 @@
#include "mongo/db/session/logical_session_id_helpers.h"
#include "mongo/db/session/session_catalog_mongod.h"
#include "mongo/db/tenant_id.h"
+#include "mongo/db/transaction/session_catalog_mongod_transaction_interface_impl.h"
#include "mongo/db/update/update_oplog_entry_serialization.h"
#include "mongo/executor/thread_pool_task_executor_test_fixture.h"
#include "mongo/logv2/log.h"
@@ -153,7 +154,10 @@ public:
_opCtx = cc().makeOperationContext();
repl::createOplog(_opCtx.get());
- MongoDSessionCatalog::set(service, std::make_unique<MongoDSessionCatalog>());
+ MongoDSessionCatalog::set(
+ service,
+ std::make_unique<MongoDSessionCatalog>(
+ std::make_unique<MongoDSessionCatalogTransactionInterfaceImpl>()));
// Ensure that we are primary.
auto replCoord = ReplicationCoordinator::get(_opCtx.get());