Fixing a number of scaling issues:

- Missed closing of file descriptor made ForkingTaskExecutor
  silently die after running out of FDs
- Tightened up scope for locks to prevent http timeout
- Simplified threadpool
This commit is contained in:
Ian Roddis
2022-01-10 13:02:10 -04:00
parent efd4078f70
commit 53308c063d
8 changed files with 96 additions and 140 deletions

View File

@@ -116,6 +116,7 @@ void daemonize()
}
namespace dl = daggy::loggers::dag_run;
std::ofstream ofh;
std::unique_ptr<dl::DAGRunLogger> loggerFactory(const rj::Value &config)
{
@@ -138,7 +139,7 @@ std::unique_ptr<dl::DAGRunLogger> loggerFactory(const rj::Value &config)
if (fn == "-")
return std::make_unique<dl::OStreamLogger>(std::cout);
std::ofstream ofh(logConfig["file"].GetString());
ofh.open(logConfig["file"].GetString());
return std::make_unique<dl::OStreamLogger>(ofh);
}
}