Fawkes API  Fawkes Development Version
lookup_thread.h
1 /***************************************************************************
2  * lookup_thread.h - Get skill exec times from db lookups
3  *
4  * Created: Tue 24 Mar 2020 09:40:18 CET 09:40
5  * Copyright 2020 Tarik Viehmann <viehmann@kbsg.rwth-aachen.de>
6  ****************************************************************************/
7 
8 /* This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 2 of the License, or
11  * (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU Library General Public License for more details.
17  *
18  * Read the full text in the LICENSE.GPL file in the doc directory.
19  */
20 
21 #pragma once
22 
23 #include "lookup_estimator.h"
24 
25 #include <aspect/configurable.h>
26 #include <aspect/logging.h>
27 #include <core/threading/thread.h>
28 #include <execution_time_estimator/aspect/execution_time_estimator.h>
29 #include <plugins/mongodb/aspect/mongodb.h>
30 
32  public fawkes::LoggingAspect,
34  public fawkes::MongoDBAspect,
36 {
37 public:
39  void init();
40  void finalize();
41 
42 private:
43  constexpr static char cfg_prefix_[] = "plugins/execution-time-estimator/lookup/";
44  std::shared_ptr<fawkes::LookupEstimator> estimator_;
45 };
Get estimates for skill execution times from samples of a mongodb database.
Definition: lookup_thread.h:36
void finalize()
Unregister the estimator.
void init()
Register the estimator.
Thread aspect to access configuration data.
Definition: configurable.h:33
An aspect to give access to the execution time estimator manager.
Thread aspect to log output.
Definition: logging.h:33
Thread aspect to access MongoDB.
Definition: mongodb.h:39
Thread class encapsulation of pthreads.
Definition: thread.h:46