Skip to content

Commit 1241b15

Browse files
mtandreievergreen
authored andcommitted
SERVER-41593 Remove the unused parameter incrementOpsAppliedStats from createIndexForApplyOps method
1 parent 9eecdb4 commit 1241b15

File tree

3 files changed

+2
-8
lines changed

3 files changed

+2
-8
lines changed

src/mongo/db/repl/oplog.cpp

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,6 @@ Status abortIndexBuild(OperationContext* opCtx,
227227
void createIndexForApplyOps(OperationContext* opCtx,
228228
const BSONObj& indexSpec,
229229
const NamespaceString& indexNss,
230-
IncrementOpsAppliedStatsFn incrementOpsAppliedStats,
231230
OplogApplication::Mode mode) {
232231
invariant(opCtx->lockState()->isCollectionLockedForMode(indexNss, MODE_X));
233232

@@ -285,10 +284,6 @@ void createIndexForApplyOps(OperationContext* opCtx,
285284
}
286285

287286
opCtx->recoveryUnit()->abandonSnapshot();
288-
289-
if (incrementOpsAppliedStats) {
290-
incrementOpsAppliedStats();
291-
}
292287
}
293288

294289
/* we write to local.oplog.rs:
@@ -745,7 +740,7 @@ const StringMap<ApplyOpMetadata> kOpsMap = {
745740
BSONObj indexSpec = cmd.removeField("createIndexes");
746741
Lock::DBLock dbLock(opCtx, nss.db(), MODE_IX);
747742
Lock::CollectionLock collLock(opCtx, nss, MODE_X);
748-
createIndexForApplyOps(opCtx, indexSpec, nss, {}, mode);
743+
createIndexForApplyOps(opCtx, indexSpec, nss, mode);
749744
return Status::OK();
750745
},
751746
{ErrorCodes::IndexAlreadyExists,

src/mongo/db/repl/oplog.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,6 @@ void signalOplogWaiters();
242242
void createIndexForApplyOps(OperationContext* opCtx,
243243
const BSONObj& indexSpec,
244244
const NamespaceString& indexNss,
245-
IncrementOpsAppliedStatsFn incrementOpsAppliedStats,
246245
OplogApplication::Mode mode);
247246

248247
/**

src/mongo/db/repl/rs_rollback.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -763,7 +763,7 @@ void rollbackDropIndexes(OperationContext* opCtx,
763763
log() << "Creating index in rollback for collection: " << *nss << ", UUID: " << uuid
764764
<< ", index: " << indexName;
765765

766-
createIndexForApplyOps(opCtx, indexSpec, *nss, {}, OplogApplication::Mode::kRecovering);
766+
createIndexForApplyOps(opCtx, indexSpec, *nss, OplogApplication::Mode::kRecovering);
767767

768768
LOG(1) << "Created index in rollback for collection: " << *nss << ", UUID: " << uuid
769769
<< ", index: " << indexName;

0 commit comments

Comments
 (0)