diff options
| author | Lucas de Castro Borges <lucas@gnuabordo.com.br> | 2025-02-11 15:07:35 -0300 |
|---|---|---|
| committer | Lucas de Castro Borges <lucas@gnuabordo.com.br> | 2025-02-11 15:07:35 -0300 |
| commit | 4cb8841196d0625dfa3825aa326f071cd27c7b8b (patch) | |
| tree | 1682a647d4463397c119183369ae6f750d5fdcff /src/mongo/s/mongos_main.cpp | |
| parent | aa03c6362cbaa767638e6eed9b031d86dd2643d1 (diff) | |
| parent | 8f0827553e09872941945a093b647a4211a9db7f (diff) | |
Update upstream source from tag 'upstream/6.0.0'master
Update to upstream version '6.0.0'
with Debian dir 5604a80ec1c96ca76f25f40d78e6ef855abec322
Diffstat (limited to 'src/mongo/s/mongos_main.cpp')
| -rw-r--r-- | src/mongo/s/mongos_main.cpp | 31 |
1 files changed, 1 insertions, 30 deletions
diff --git a/src/mongo/s/mongos_main.cpp b/src/mongo/s/mongos_main.cpp index 665f3fe08d4..0504b714aec 100644 --- a/src/mongo/s/mongos_main.cpp +++ b/src/mongo/s/mongos_main.cpp @@ -127,10 +127,6 @@ #include "mongo/util/text.h" #include "mongo/util/version.h" -#ifdef __linux__ -#include <sys/prctl.h> -#endif - namespace mongo { using logv2::LogComponent; @@ -316,10 +312,7 @@ void cleanupTask(const ShutdownTaskArgs& shutdownArgs) { ReplicaSetMonitor::shutdown(); - { - stdx::lock_guard lg(client); - opCtx->setIsExecutingShutdown(); - } + opCtx->setIsExecutingShutdown(); if (serviceContext) { serviceContext->setKillAllOperations(); @@ -348,7 +341,6 @@ void cleanupTask(const ShutdownTaskArgs& shutdownArgs) { } if (auto pool = Grid::get(opCtx)->getExecutorPool()) { - LOGV2_OPTIONS(7698300, {LogComponent::kSharding}, "Shutting down the ExecutorPool"); pool->shutdownAndJoin(); } @@ -357,13 +349,6 @@ void cleanupTask(const ShutdownTaskArgs& shutdownArgs) { } if (Grid::get(serviceContext)->isShardingInitialized()) { - // The CatalogCache must be shuted down before shutting down the CatalogCacheLoader as - // the CatalogCache may try to schedule work on CatalogCacheLoader and fail. - LOGV2_OPTIONS(7698301, {LogComponent::kSharding}, "Shutting down the CatalogCache"); - Grid::get(serviceContext)->catalogCache()->shutDownAndJoin(); - - LOGV2_OPTIONS( - 7698302, {LogComponent::kSharding}, "Shutting down the CatalogCacheLoader"); CatalogCacheLoader::get(serviceContext).shutDown(); } @@ -860,18 +845,6 @@ std::unique_ptr<AuthzManagerExternalState> createAuthzManagerExternalStateMongos return std::make_unique<AuthzManagerExternalStateMongos>(); } -void disableMongosTHPUnderTestingEnvironment() { -#ifdef __linux__ - if (TestingProctor::instance().isEnabled()) { - if (prctl(PR_SET_THP_DISABLE, 1, 0, 0, 0) == -1) { - LOGV2_WARNING(8751802, "Could not disable THP on mongos"); - } else { - LOGV2_INFO(8751803, "Successfully disabled THP on mongos"); - } - } -#endif -} - ExitCode main(ServiceContext* serviceContext) { serviceContext->setFastClockSource(FastClockSourceFactory::create(Milliseconds{10})); @@ -946,8 +919,6 @@ ExitCode mongos_main(int argc, char* argv[]) { return EXIT_ABRUPT; } - disableMongosTHPUnderTestingEnvironment(); - try { auto serviceContextHolder = ServiceContext::make(); serviceContextHolder->registerClientObserver( |
