Commit 8f9b1600 authored by Tom Zander's avatar Tom Zander

Make mapper close more agressive

I expect that it would be bettter to make this configurable
because it is based on what the rest of the system is used for.
parent 58a9baba
Pipeline #37008484 passed with stages
in 25 minutes and 44 seconds
......@@ -859,7 +859,7 @@ void Blocks::DBPrivate::closeFiles()
{
std::lock_guard<std::recursive_mutex> lock_(lock);
size_t count = fileHistory.size();
const int64_t timeOut = GetTime() - (count < 100 ? 30 : 10); // amount of seconds to keep files open
const int64_t timeOut = GetTime() - (count < 100 ? 15 : 7); // amount of seconds to keep files open
for (auto iter = fileHistory.begin(); iter != fileHistory.end();) {
if (iter->lastAccessed < timeOut)
iter = fileHistory.erase(iter);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment