Remove thread pool selection code for now
This commit is contained in:
parent
9df60f074b
commit
034020e152
4 changed files with 2 additions and 52 deletions
|
@ -2,37 +2,11 @@
|
|||
#include "html_fetch_task.hpp"
|
||||
#include "eventia/eventia.hpp"
|
||||
#include "eventia/timer.hpp"
|
||||
|
||||
#include "orotool_config.hpp"
|
||||
#if THREADPOOL == THREADPOOL_TASKFLOW
|
||||
# include <taskflow/taskflow.hpp>
|
||||
#elif THREADPOOL == THREADPOOL_ROAR11
|
||||
# include "roar11/ThreadPool.hpp"
|
||||
#endif
|
||||
|
||||
#include "roar11/ThreadPool.hpp"
|
||||
#include <iostream>
|
||||
|
||||
#if THREADPOOL == THREADPOOL_TASKFLOW
|
||||
namespace tf {
|
||||
class Taskflow;
|
||||
class Subflow;
|
||||
} //namespace tf
|
||||
#elif THREADPOOL == THREADPOOL_ROAR11
|
||||
namespace roar11 {
|
||||
class ThreadPool;
|
||||
} //namespace roar11
|
||||
#endif
|
||||
|
||||
namespace duck {
|
||||
namespace {
|
||||
#if THREADPOOL == THREADPOOL_ROAR11
|
||||
typedef roar11::ThreadPool threadpool_type;
|
||||
typedef roar11::ThreadPool subpool_type;
|
||||
#elif THREADPOOL == THREADPOOL_TASKFLOW
|
||||
typedef tf::Taskflow threadpool_type;
|
||||
typedef tf::Subflow subpool_type;
|
||||
#endif
|
||||
|
||||
//class KeepaliveTimer : public ev::timer {
|
||||
//public:
|
||||
// KeepaliveTimer (ev::loop_ref& loop, RunningPool::subpool_type*) {
|
||||
|
@ -45,17 +19,10 @@ namespace {
|
|||
// }
|
||||
//};
|
||||
|
||||
#if THREADPOOL == THREADPOOL_TASKFLOW
|
||||
void join(tf::Executor& executor) {
|
||||
executor.wait_for_all();
|
||||
std::cout << "all tasks completed\n";
|
||||
}
|
||||
#else
|
||||
void join(threadpool_type& pool) {
|
||||
void join(roar11::ThreadPool& pool) {
|
||||
pool.join();
|
||||
std::cout << "all tasks completed\n";
|
||||
}
|
||||
#endif
|
||||
|
||||
} //unnamed namespace
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue