Mercurial > hg > orthanc
changeset 5183:5ec3dcdf78b9
renamed HousekeeperThread as MemoryTrimmingThread to avoid confusion with Housekeeper plugin
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Sat, 25 Mar 2023 12:07:39 +0100 |
parents | cddf28cfcd8d |
children | dd085f7e7e71 |
files | OrthancServer/Sources/ServerContext.cpp OrthancServer/Sources/ServerContext.h |
diffstat | 2 files changed, 10 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/OrthancServer/Sources/ServerContext.cpp Sat Mar 25 11:38:37 2023 +0100 +++ b/OrthancServer/Sources/ServerContext.cpp Sat Mar 25 12:07:39 2023 +0100 @@ -109,10 +109,10 @@ #if HAVE_MALLOC_TRIM == 1 - void ServerContext::HousekeeperThread(ServerContext* that, - unsigned int sleepDelay) + void ServerContext::MemoryTrimmingThread(ServerContext* that, + unsigned int sleepDelay) { - // note, right now, this thread is started only if malloc_trim is defined + // This thread is started only if malloc_trim is defined while (!that->done_) { boost::this_thread::sleep(boost::posix_time::milliseconds(sleepDelay)); @@ -439,9 +439,9 @@ changeThread_ = boost::thread(ChangeThread, this, (unitTesting ? 20 : 100)); #if HAVE_MALLOC_TRIM == 1 - housekeeperThread_ = boost::thread(HousekeeperThread, this, 100); + memoryTrimmingThread_ = boost::thread(MemoryTrimmingThread, this, 100); #else - LOG(INFO) << "Your platform does not support malloc_trim(), not starting the housekeeper thread"; + LOG(INFO) << "Your platform does not support malloc_trim(), not starting the memory trimming thread"; #endif dynamic_cast<DcmtkTranscoder&>(*dcmtkTranscoder_).SetLossyQuality(lossyQuality); @@ -486,9 +486,9 @@ saveJobsThread_.join(); } - if (housekeeperThread_.joinable()) + if (memoryTrimmingThread_.joinable()) { - housekeeperThread_.join(); + memoryTrimmingThread_.join(); } jobsEngine_.GetRegistry().ResetObserver();
--- a/OrthancServer/Sources/ServerContext.h Sat Mar 25 11:38:37 2023 +0100 +++ b/OrthancServer/Sources/ServerContext.h Sat Mar 25 12:07:39 2023 +0100 @@ -188,8 +188,8 @@ unsigned int sleepDelay); #if HAVE_MALLOC_TRIM == 1 - static void HousekeeperThread(ServerContext* that, - unsigned int sleepDelay); + static void MemoryTrimmingThread(ServerContext* that, + unsigned int sleepDelay); #endif void SaveJobsEngine(); @@ -235,7 +235,7 @@ SharedMessageQueue pendingChanges_; boost::thread changeThread_; boost::thread saveJobsThread_; - boost::thread housekeeperThread_; + boost::thread memoryTrimmingThread_; std::unique_ptr<SharedArchive> queryRetrieveArchive_; std::string defaultLocalAet_;