From 68a1b16ca1ed6d8b45257742340fa35ab8a0b19e Mon Sep 17 00:00:00 2001 From: Pavi Vetriselvan Date: Tue, 14 May 2019 12:38:51 -0400 Subject: SERVER-40937 change DB X lock to IX lock during secondary multikey updates --- src/mongo/db/repl/storage_interface_impl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mongo/db/repl/storage_interface_impl.cpp') diff --git a/src/mongo/db/repl/storage_interface_impl.cpp b/src/mongo/db/repl/storage_interface_impl.cpp index 7bb1dfc9ab1..a7ee8bd067d 100644 --- a/src/mongo/db/repl/storage_interface_impl.cpp +++ b/src/mongo/db/repl/storage_interface_impl.cpp @@ -537,7 +537,7 @@ Status StorageInterfaceImpl::setIndexIsMultikey(OperationContext* opCtx, } return writeConflictRetry(opCtx, "StorageInterfaceImpl::setIndexIsMultikey", nss.ns(), [&] { - AutoGetCollection autoColl(opCtx, nss, MODE_X); + AutoGetCollection autoColl(opCtx, nss, MODE_IX); auto collectionResult = getCollection( autoColl, nss, "The collection must exist before setting an index to multikey."); if (!collectionResult.isOK()) { -- cgit v1.2.1