summaryrefslogtreecommitdiff
path: root/src/mongo/db/query/plan_executor_impl.cpp
diff options
context:
space:
mode:
authorLingzhi Deng <lingzhi.deng@mongodb.com>2020-01-06 15:42:38 +0000
committerevergreen <evergreen@mongodb.com>2020-01-06 15:42:38 +0000
commitd628d67126fb51cebf8960f4d73816f94f2cb99d (patch)
treee0386b8034ff732779969e49f875fda2cc815189 /src/mongo/db/query/plan_executor_impl.cpp
parenta047dc462b3e9f828ad43ea1ff5c920f633b17e9 (diff)
downloadmongo-d628d67126fb51cebf8960f4d73816f94f2cb99d.tar.gz
SERVER-44707: Store lastKnownCommittedOpTime in ClientCursor for exhaust getMore
Diffstat (limited to 'src/mongo/db/query/plan_executor_impl.cpp')
-rw-r--r--src/mongo/db/query/plan_executor_impl.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/mongo/db/query/plan_executor_impl.cpp b/src/mongo/db/query/plan_executor_impl.cpp
index cc2df087217..c4e1bb83c7d 100644
--- a/src/mongo/db/query/plan_executor_impl.cpp
+++ b/src/mongo/db/query/plan_executor_impl.cpp
@@ -627,7 +627,14 @@ PlanExecutor::ExecState PlanExecutorImpl::_getNextImpl(Snapshotted<Document>* ob
} else if (PlanStage::NEED_TIME == code) {
// Fall through to yield check at end of large conditional.
} else if (PlanStage::IS_EOF == code) {
- if (MONGO_unlikely(planExecutorHangBeforeShouldWaitForInserts.shouldFail())) {
+ if (MONGO_unlikely(planExecutorHangBeforeShouldWaitForInserts.shouldFail(
+ [this](const BSONObj& data) {
+ if (data.hasField("namespace") &&
+ _nss != NamespaceString(data.getStringField("namespace"))) {
+ return false;
+ }
+ return true;
+ }))) {
log() << "PlanExecutor - planExecutorHangBeforeShouldWaitForInserts fail point "
"enabled. Blocking until fail point is disabled.";
planExecutorHangBeforeShouldWaitForInserts.pauseWhileSet();