diff options
Diffstat (limited to 'src/mongo/db/pipeline')
4 files changed, 8 insertions, 20 deletions
diff --git a/src/mongo/db/pipeline/document_source_writer.h b/src/mongo/db/pipeline/document_source_writer.h index 9c175890ecf..b91c49a90db 100644 --- a/src/mongo/db/pipeline/document_source_writer.h +++ b/src/mongo/db/pipeline/document_source_writer.h @@ -65,7 +65,7 @@ public: } repl::ReadConcernArgs::get(_opCtx) = repl::ReadConcernArgs(); - _opCtx->recoveryUnit()->setTimestampReadSource(RecoveryUnit::kUnset); + _opCtx->recoveryUnit()->setTimestampReadSource(RecoveryUnit::ReadSource::kNoTimestamp); } ~DocumentSourceWriteBlock() { diff --git a/src/mongo/db/pipeline/expression_context.h b/src/mongo/db/pipeline/expression_context.h index 6cd1bba4f3b..5140d8ea32f 100644 --- a/src/mongo/db/pipeline/expression_context.h +++ b/src/mongo/db/pipeline/expression_context.h @@ -328,10 +328,6 @@ public: // 'jsHeapLimitMB' server parameter. boost::optional<int> jsHeapLimitMB; - // When set this timeout limits the allowed execution time for a JavaScript function invocation - // under any Scope returned by getJsExecWithScope(). - int jsFnTimeoutMillis; - // An interface for accessing information or performing operations that have different // implementations on mongod and mongos, or that only make sense on one of the two. // Additionally, putting some of this functionality behind an interface prevents aggregation diff --git a/src/mongo/db/pipeline/process_interface/common_process_interface.cpp b/src/mongo/db/pipeline/process_interface/common_process_interface.cpp index 330ef41693e..b6b304c348b 100644 --- a/src/mongo/db/pipeline/process_interface/common_process_interface.cpp +++ b/src/mongo/db/pipeline/process_interface/common_process_interface.cpp @@ -184,15 +184,11 @@ bool CommonProcessInterface::keyPatternNamesExactPaths(const BSONObj& keyPattern boost::optional<ChunkVersion> CommonProcessInterface::refreshAndGetCollectionVersion( const boost::intrusive_ptr<ExpressionContext>& expCtx, const NamespaceString& nss) const { - const bool forceRefreshFromThisThread = false; - auto cm = uassertStatusOK( - Grid::get(expCtx->opCtx) - ->catalogCache() - ->getCollectionRoutingInfoWithRefresh(expCtx->opCtx, nss, forceRefreshFromThisThread)); - if (cm.isSharded()) { - return cm.getVersion(); - } - return boost::none; + const auto cm = uassertStatusOK(Grid::get(expCtx->opCtx) + ->catalogCache() + ->getCollectionRoutingInfoWithRefresh(expCtx->opCtx, nss)); + + return cm.isSharded() ? boost::make_optional(cm.getVersion()) : boost::none; } std::vector<FieldPath> CommonProcessInterface::_shardKeyToDocumentKeyFields( diff --git a/src/mongo/db/pipeline/sharded_agg_helpers.h b/src/mongo/db/pipeline/sharded_agg_helpers.h index 13a20fee607..c63ac997a32 100644 --- a/src/mongo/db/pipeline/sharded_agg_helpers.h +++ b/src/mongo/db/pipeline/sharded_agg_helpers.h @@ -245,13 +245,9 @@ auto shardVersionRetry(OperationContext* opCtx, str::stream() << "StaleConfig error on unexpected namespace. Expected " << nss << ", received " << staleInfo->getNss()); catalogCache->invalidateShardOrEntireCollectionEntryForShardedCollection( - opCtx, - nss, - staleInfo->getVersionWanted(), - staleInfo->getVersionReceived(), - staleInfo->getShardId()); + nss, staleInfo->getVersionWanted(), staleInfo->getShardId()); } else { - catalogCache->onEpochChange(nss); + catalogCache->invalidateCollectionEntry_LINEARIZABLE(nss); } if (!logAndTestMaxRetries(e)) { throw; |