summaryrefslogtreecommitdiff
path: root/src/mongo/db/repl/tenant_migration_donor_op_observer.h
diff options
context:
space:
mode:
authorBenety Goh <benety@mongodb.com>2023-05-09 15:57:46 -0400
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2023-05-10 00:47:36 +0000
commit1a58eaf299e732d3a7e3e800eeb780d8c9b00212 (patch)
treee8190badb84d02d043828021da0635f2745605d8 /src/mongo/db/repl/tenant_migration_donor_op_observer.h
parentbfd9e0db11fffea0b28e4be31d8aae2c95e1d35b (diff)
downloadmongo-1a58eaf299e732d3a7e3e800eeb780d8c9b00212.tar.gz
SERVER-76894 eliminate unnecessary OpObserver overrides using OpObserverNoop for base class
Diffstat (limited to 'src/mongo/db/repl/tenant_migration_donor_op_observer.h')
-rw-r--r--src/mongo/db/repl/tenant_migration_donor_op_observer.h180
1 files changed, 2 insertions, 178 deletions
diff --git a/src/mongo/db/repl/tenant_migration_donor_op_observer.h b/src/mongo/db/repl/tenant_migration_donor_op_observer.h
index b7d624283b9..b3ad0ac7d4f 100644
--- a/src/mongo/db/repl/tenant_migration_donor_op_observer.h
+++ b/src/mongo/db/repl/tenant_migration_donor_op_observer.h
@@ -29,7 +29,7 @@
#pragma once
-#include "mongo/db/op_observer/op_observer.h"
+#include "mongo/db/op_observer/op_observer_noop.h"
namespace mongo {
namespace repl {
@@ -37,7 +37,7 @@ namespace repl {
/**
* OpObserver for tenant migration donor.
*/
-class TenantMigrationDonorOpObserver final : public OpObserver {
+class TenantMigrationDonorOpObserver final : public OpObserverNoop {
TenantMigrationDonorOpObserver(const TenantMigrationDonorOpObserver&) = delete;
TenantMigrationDonorOpObserver& operator=(const TenantMigrationDonorOpObserver&) = delete;
@@ -45,52 +45,6 @@ public:
TenantMigrationDonorOpObserver() = default;
~TenantMigrationDonorOpObserver() = default;
- void onModifyCollectionShardingIndexCatalog(OperationContext* opCtx,
- const NamespaceString& nss,
- const UUID& uuid,
- BSONObj indexDoc) final {}
-
- void onCreateGlobalIndex(OperationContext* opCtx,
- const NamespaceString& globalIndexNss,
- const UUID& globalIndexUUID) final{};
-
- void onDropGlobalIndex(OperationContext* opCtx,
- const NamespaceString& globalIndexNss,
- const UUID& globalIndexUUID,
- long long numKeys) final{};
-
- void onCreateIndex(OperationContext* opCtx,
- const NamespaceString& nss,
- const UUID& uuid,
- BSONObj indexDoc,
- bool fromMigrate) final {}
-
- void onStartIndexBuild(OperationContext* opCtx,
- const NamespaceString& nss,
- const UUID& collUUID,
- const UUID& indexBuildUUID,
- const std::vector<BSONObj>& indexes,
- bool fromMigrate) final {}
-
- void onStartIndexBuildSinglePhase(OperationContext* opCtx, const NamespaceString& nss) final {}
-
- void onAbortIndexBuildSinglePhase(OperationContext* opCtx, const NamespaceString& nss) final {}
-
- void onCommitIndexBuild(OperationContext* opCtx,
- const NamespaceString& nss,
- const UUID& collUUID,
- const UUID& indexBuildUUID,
- const std::vector<BSONObj>& indexes,
- bool fromMigrate) final {}
-
- void onAbortIndexBuild(OperationContext* opCtx,
- const NamespaceString& nss,
- const UUID& collUUID,
- const UUID& indexBuildUUID,
- const std::vector<BSONObj>& indexes,
- const Status& cause,
- bool fromMigrate) final {}
-
void onInserts(OperationContext* opCtx,
const CollectionPtr& coll,
std::vector<InsertStatement>::const_iterator first,
@@ -99,18 +53,6 @@ public:
bool defaultFromMigrate,
InsertsOpStateAccumulator* opAccumulator = nullptr) final;
- void onInsertGlobalIndexKey(OperationContext* opCtx,
- const NamespaceString& globalIndexNss,
- const UUID& globalIndexUuid,
- const BSONObj& key,
- const BSONObj& docKey) final{};
-
- void onDeleteGlobalIndexKey(OperationContext* opCtx,
- const NamespaceString& globalIndexNss,
- const UUID& globalIndexUuid,
- const BSONObj& key,
- const BSONObj& docKey) final {}
-
void onUpdate(OperationContext* opCtx,
const OplogUpdateEntryArgs& args,
OpStateAccumulator* opAccumulator = nullptr) final;
@@ -125,33 +67,6 @@ public:
const OplogDeleteEntryArgs& args,
OpStateAccumulator* opAccumulator = nullptr) final;
- void onInternalOpMessage(OperationContext* opCtx,
- const NamespaceString& nss,
- const boost::optional<UUID>& uuid,
- const BSONObj& msgObj,
- const boost::optional<BSONObj> o2MsgObj,
- const boost::optional<repl::OpTime> preImageOpTime,
- const boost::optional<repl::OpTime> postImageOpTime,
- const boost::optional<repl::OpTime> prevWriteOpTimeInTransaction,
- const boost::optional<OplogSlot> slot) final {}
-
- void onCreateCollection(OperationContext* opCtx,
- const CollectionPtr& coll,
- const NamespaceString& collectionName,
- const CollectionOptions& options,
- const BSONObj& idIndex,
- const OplogSlot& createOpTime,
- bool fromMigrate) final {}
-
- void onCollMod(OperationContext* opCtx,
- const NamespaceString& nss,
- const UUID& uuid,
- const BSONObj& collModCmd,
- const CollectionOptions& oldCollOptions,
- boost::optional<IndexCollModInfo> indexInfo) final {}
-
- void onDropDatabase(OperationContext* opCtx, const DatabaseName& dbName) final {}
-
repl::OpTime onDropCollection(OperationContext* opCtx,
const NamespaceString& collectionName,
const UUID& uuid,
@@ -159,97 +74,6 @@ public:
CollectionDropType dropType,
bool markFromMigrate) final;
- void onDropIndex(OperationContext* opCtx,
- const NamespaceString& nss,
- const UUID& uuid,
- const std::string& indexName,
- const BSONObj& indexInfo) final {}
-
- void onRenameCollection(OperationContext* opCtx,
- const NamespaceString& fromCollection,
- const NamespaceString& toCollection,
- const UUID& uuid,
- const boost::optional<UUID>& dropTargetUUID,
- std::uint64_t numRecords,
- bool stayTemp,
- bool markFromMigrate) final {}
-
- void onImportCollection(OperationContext* opCtx,
- const UUID& importUUID,
- const NamespaceString& nss,
- long long numRecords,
- long long dataSize,
- const BSONObj& catalogEntry,
- const BSONObj& storageMetadata,
- bool isDryRun) final {}
-
- repl::OpTime preRenameCollection(OperationContext* opCtx,
- const NamespaceString& fromCollection,
- const NamespaceString& toCollection,
- const UUID& uuid,
- const boost::optional<UUID>& dropTargetUUID,
- std::uint64_t numRecords,
- bool stayTemp,
- bool markFromMigrate) final {
- return repl::OpTime();
- }
- void postRenameCollection(OperationContext* opCtx,
- const NamespaceString& fromCollection,
- const NamespaceString& toCollection,
- const UUID& uuid,
- const boost::optional<UUID>& dropTargetUUID,
- bool stayTemp) final {}
- void onApplyOps(OperationContext* opCtx,
- const DatabaseName& dbName,
- const BSONObj& applyOpCmd) final {}
-
- void onEmptyCapped(OperationContext* opCtx,
- const NamespaceString& collectionName,
- const UUID& uuid) final {}
-
- void onTransactionStart(OperationContext* opCtx) final {}
-
- void onUnpreparedTransactionCommit(OperationContext* opCtx,
- const TransactionOperations& transactionOperations,
- OpStateAccumulator* opAccumulator = nullptr) final {}
-
- void onPreparedTransactionCommit(
- OperationContext* opCtx,
- OplogSlot commitOplogEntryOpTime,
- Timestamp commitTimestamp,
- const std::vector<repl::ReplOperation>& statements) noexcept final {}
-
- void onTransactionPrepareNonPrimary(OperationContext* opCtx,
- const std::vector<repl::OplogEntry>& statements,
- const repl::OpTime& prepareOpTime) final {}
-
- std::unique_ptr<ApplyOpsOplogSlotAndOperationAssignment> preTransactionPrepare(
- OperationContext* opCtx,
- const std::vector<OplogSlot>& reservedSlots,
- const TransactionOperations& transactionOperations,
- Date_t wallClockTime) final {
- return nullptr;
- }
-
- void onTransactionPrepare(
- OperationContext* opCtx,
- const std::vector<OplogSlot>& reservedSlots,
- const TransactionOperations& transactionOperations,
- const ApplyOpsOplogSlotAndOperationAssignment& applyOpsOperationAssignment,
- size_t numberOfPrePostImagesToWrite,
- Date_t wallClockTime) final {}
-
- void onTransactionAbort(OperationContext* opCtx,
- boost::optional<OplogSlot> abortOplogEntryOpTime) final {}
-
- void onBatchedWriteStart(OperationContext* opCtx) final {}
-
- void onBatchedWriteCommit(OperationContext* opCtx) final {}
-
- void onBatchedWriteAbort(OperationContext* opCtx) final {}
-
- void onReplicationRollback(OperationContext* opCtx, const RollbackObserverInfo& rbInfo) final {}
-
void onMajorityCommitPointUpdate(ServiceContext* service,
const repl::OpTime& newCommitPoint) final;
};