Adding RedisLogger as a default for daggyd
This commit is contained in:
@@ -9,15 +9,17 @@
|
|||||||
|
|
||||||
// Add executors here
|
// Add executors here
|
||||||
#ifdef DAGGY_ENABLE_SLURM
|
#ifdef DAGGY_ENABLE_SLURM
|
||||||
|
|
||||||
#include <daggy/executors/task/SlurmTaskExecutor.hpp>
|
#include <daggy/executors/task/SlurmTaskExecutor.hpp>
|
||||||
|
|
||||||
#else
|
#else
|
||||||
#include <daggy/executors/task/ForkingTaskExecutor.hpp>
|
#include <daggy/executors/task/ForkingTaskExecutor.hpp>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Add loggers here
|
// Add loggers here
|
||||||
|
#ifdef DAGGY_ENABLE_REDIS
|
||||||
|
#include <daggy/loggers/dag_run/RedisLogger.hpp>
|
||||||
|
#else
|
||||||
#include <daggy/loggers/dag_run/OStreamLogger.hpp>
|
#include <daggy/loggers/dag_run/OStreamLogger.hpp>
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
@@ -195,7 +197,11 @@ int main(int argc, char **argv)
|
|||||||
std::unique_ptr<daggy::loggers::dag_run::DAGRunLogger> logger;
|
std::unique_ptr<daggy::loggers::dag_run::DAGRunLogger> logger;
|
||||||
if (logFileName == "-") {
|
if (logFileName == "-") {
|
||||||
logger =
|
logger =
|
||||||
|
#ifdef DAGGY_ENABLE_REDIS
|
||||||
|
std::make_unique<daggy::loggers::dag_run::RedisLogger>();
|
||||||
|
#else
|
||||||
std::make_unique<daggy::loggers::dag_run::OStreamLogger>(std::cout);
|
std::make_unique<daggy::loggers::dag_run::OStreamLogger>(std::cout);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
logFH.open(logFileName, std::ios::app);
|
logFH.open(logFileName, std::ios::app);
|
||||||
|
|||||||
Reference in New Issue
Block a user