summaryrefslogtreecommitdiff
path: root/src/mongo/s/query/store_possible_cursor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/s/query/store_possible_cursor.cpp')
-rw-r--r--src/mongo/s/query/store_possible_cursor.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/mongo/s/query/store_possible_cursor.cpp b/src/mongo/s/query/store_possible_cursor.cpp
index 13477f1e14e..1e3b7d03306 100644
--- a/src/mongo/s/query/store_possible_cursor.cpp
+++ b/src/mongo/s/query/store_possible_cursor.cpp
@@ -39,7 +39,8 @@
namespace mongo {
-StatusWith<BSONObj> storePossibleCursor(const HostAndPort& server,
+StatusWith<BSONObj> storePossibleCursor(OperationContext* txn,
+ const HostAndPort& server,
const BSONObj& cmdResult,
const NamespaceString& requestedNss,
executor::TaskExecutor* executor,
@@ -61,10 +62,11 @@ StatusWith<BSONObj> storePossibleCursor(const HostAndPort& server,
params.remotes.emplace_back(server, incomingCursorResponse.getValue().getCursorId());
- auto ccc = ClusterClientCursorImpl::make(executor, std::move(params));
+ auto ccc = ClusterClientCursorImpl::make(txn, executor, std::move(params));
auto clusterCursorId =
- cursorManager->registerCursor(ccc.releaseCursor(),
+ cursorManager->registerCursor(txn,
+ ccc.releaseCursor(),
requestedNss,
ClusterCursorManager::CursorType::NamespaceNotSharded,
ClusterCursorManager::CursorLifetime::Mortal);