diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2023-11-02 15:33:22 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-02 15:33:22 +0100 |
commit | 756ac9de004347d2d5b8893b43c37eb6ac930560 (patch) | |
tree | f0ce3b5db120b40bfa264593627b010fe7a309cc /searchcore/src | |
parent | 875422da13b5236fe368709d66f4696f06fca3f2 (diff) | |
parent | f2983f6f300630f6aec7538d75eed6356fe12da6 (diff) |
Merge pull request #29194 from vespa-engine/vekterli/merge-memory-usage-soft-limiting
Add configurable soft limiting of memory used by merge operations on a content node
Diffstat (limited to 'searchcore/src')
-rw-r--r-- | searchcore/src/apps/proton/proton.cpp | 12 | ||||
-rw-r--r-- | searchcore/src/vespa/searchcore/bmcluster/bm_node.cpp | 2 |
2 files changed, 8 insertions, 6 deletions
diff --git a/searchcore/src/apps/proton/proton.cpp b/searchcore/src/apps/proton/proton.cpp index 129091606b3..4c20c40b406 100644 --- a/searchcore/src/apps/proton/proton.cpp +++ b/searchcore/src/apps/proton/proton.cpp @@ -109,7 +109,8 @@ class ProtonServiceLayerProcess : public storage::ServiceLayerProcess { public: ProtonServiceLayerProcess(const config::ConfigUri & configUri, proton::Proton & proton, FNET_Transport& transport, - const vespalib::string& file_distributor_connection_spec); + const vespalib::string& file_distributor_connection_spec, + const vespalib::HwInfo& hw_info); ~ProtonServiceLayerProcess() override { shutdown(); } void shutdown() override; @@ -130,8 +131,9 @@ public: ProtonServiceLayerProcess::ProtonServiceLayerProcess(const config::ConfigUri & configUri, proton::Proton & proton, FNET_Transport& transport, - const vespalib::string& file_distributor_connection_spec) - : ServiceLayerProcess(configUri), + const vespalib::string& file_distributor_connection_spec, + const vespalib::HwInfo& hw_info) + : ServiceLayerProcess(configUri, hw_info), _proton(proton), _transport(transport), _file_distributor_connection_spec(file_distributor_connection_spec), @@ -259,18 +261,18 @@ App::startAndRun(FNET_Transport & transport, int argc, char **argv) { proton.init(configSnapshot); } vespalib::string file_distributor_connection_spec = configSnapshot->getFiledistributorrpcConfig().connectionspec; - configSnapshot.reset(); std::unique_ptr<ProtonServiceLayerProcess> spiProton; if ( ! params.serviceidentity.empty()) { spiProton = std::make_unique<ProtonServiceLayerProcess>(identityUri.createWithNewId(params.serviceidentity), proton, transport, - file_distributor_connection_spec); + file_distributor_connection_spec, configSnapshot->getHwInfo()); spiProton->setupConfig(subscribeTimeout); spiProton->createNode(); EV_STARTED("servicelayer"); } else { proton.getMetricManager().init(identityUri); } + configSnapshot.reset(); EV_STARTED("proton"); while (!(SIG::INT.check() || SIG::TERM.check() || (spiProton && spiProton->getNode().attemptedStopped()))) { std::this_thread::sleep_for(1000ms); diff --git a/searchcore/src/vespa/searchcore/bmcluster/bm_node.cpp b/searchcore/src/vespa/searchcore/bmcluster/bm_node.cpp index 9a0a2968c69..808747034ac 100644 --- a/searchcore/src/vespa/searchcore/bmcluster/bm_node.cpp +++ b/searchcore/src/vespa/searchcore/bmcluster/bm_node.cpp @@ -243,7 +243,7 @@ public: MyServiceLayerProcess::MyServiceLayerProcess(const config::ConfigUri& configUri, PersistenceProvider& provider, std::unique_ptr<storage::IStorageChainBuilder> chain_builder) - : ServiceLayerProcess(configUri), + : ServiceLayerProcess(configUri, vespalib::HwInfo()), _provider(provider) { if (chain_builder) { |