Mēnsūra
|
Performs parallel processing of datasets. More...
#include <RunManager.hpp>
Public Member Functions | |
template<typename InputIt > | |
RunManager (InputIt const &datasetsBegin, InputIt const &datasetsEnd) | |
Constructor from a container of instances of Dataset. | |
RunManager (RunManager const &)=delete | |
Copy constructor is deleted. | |
RunManager & | operator= (RunManager const &)=delete |
Assignment operator is deleted. | |
void | PrintSummary () const |
Prints a summary with numbers of events processed and accepted by each plugin. More... | |
void | Process (int nThreads) |
Processes datasets with a pool of nThreads threads. | |
void | Process (double loadFraction) |
Processes datasets with a pool of threads. More... | |
void | RegisterService (Service *service) |
Adds a new service. More... | |
void | RegisterPlugin (Plugin *plugin, std::initializer_list< std::string > const &dependencies) |
Adds a new plugin with explicit dependencies to the execution path. More... | |
void | RegisterPlugin (Plugin *plugin) |
Adds a new plugin to the execution path. More... | |
Friends | |
class | Processor |
Performs parallel processing of datasets.
The class hosts a list of atomic (containing a single file each) datasets and manages a thread pool that processes them. It only forwards parameters, and the actual processing is delegated to instances of dedicated class Processor.
Some of data members are accessed directly by the friend class Processor.
void RunManager::PrintSummary | ( | ) | const |
Prints a summary with numbers of events processed and accepted by each plugin.
The summary is available only after datasets have been processed.
void RunManager::Process | ( | double | loadFraction | ) |
Processes datasets with a pool of threads.
Number of threads is determined by multiplying total supported number of concurrent threads by the given fraction.
void RunManager::RegisterPlugin | ( | Plugin * | plugin, |
std::initializer_list< std::string > const & | dependencies | ||
) |
Adds a new plugin with explicit dependencies to the execution path.
Directly calls Processor::RegisterPlugin for the underlying template processor. Consult documentation for that method.
void RunManager::RegisterPlugin | ( | Plugin * | plugin | ) |
Adds a new plugin to the execution path.
Directly calls Processor::RegisterPlugin for the underlying template processor. Consult documentation for that method.
void RunManager::RegisterService | ( | Service * | service | ) |
Adds a new service.
Directly calls Processor::RegisterService for the underlying template processor. Consult documentation for that method.