3#ifndef _Session_0_dunedaq__confmodel_0_confmodel_H_
4#define _Session_0_dunedaq__confmodel_0_confmodel_H_
23 class ConnectivityService;
51 virtual
void init(
bool init_children);
69 virtual
void print(
unsigned int offset,
bool print_header,
std::ostream& s) const;
140 std::lock_guard scoped_lock(
m_mutex);
156 std::lock_guard scoped_lock(
m_mutex);
173 std::lock_guard scoped_lock(
m_mutex);
189 std::lock_guard scoped_lock(
m_mutex);
206 std::lock_guard scoped_lock(
m_mutex);
222 std::lock_guard scoped_lock(
m_mutex);
239 std::lock_guard scoped_lock(
m_mutex);
255 std::lock_guard scoped_lock(
m_mutex);
266 struct Controller_log_level {
267 inline static const std::string
CRITICAL =
"CRITICAL";
268 inline static const std::string
ERROR =
"ERROR";
269 inline static const std::string
WARNING =
"WARNING";
270 inline static const std::string
INFO =
"INFO";
271 inline static const std::string
DEBUG =
"DEBUG";
284 std::lock_guard scoped_lock(
m_mutex);
300 std::lock_guard scoped_lock(
m_mutex);
317 std::lock_guard scoped_lock(
m_mutex);
333 std::lock_guard scoped_lock(
m_mutex);
369 std::lock_guard scoped_lock(
m_mutex);
393 const std::vector<const dunedaq::confmodel::VariableBase*>&
396 std::lock_guard scoped_lock(
m_mutex);
411 set_environment(
const std::vector<const dunedaq::confmodel::VariableBase*>& value);
420 const std::vector<const dunedaq::confmodel::ResourceBase*>&
423 std::lock_guard scoped_lock(
m_mutex);
438 set_disabled(
const std::vector<const dunedaq::confmodel::ResourceBase*>& value);
450 std::lock_guard scoped_lock(
m_mutex);
455 std::ostringstream text;
456 text <<
"relationship \"" <<
s_segment <<
"\" of object " <<
this <<
" is not set";
479 const std::vector<const dunedaq::confmodel::Application*>&
482 std::lock_guard scoped_lock(
m_mutex);
507 std::lock_guard scoped_lock(
m_mutex);
512 std::ostringstream text;
539 std::lock_guard scoped_lock(
m_mutex);
544 std::ostringstream text;
545 text <<
"relationship \"" <<
s_opmon_uri <<
"\" of object " <<
this <<
" is not set";
585 void set_disabled(
const std::set<const dunedaq::confmodel::Component *>& objs)
const;
592 void set_enabled(
const std::set<const dunedaq::confmodel::Component *>& objs)
const;
599 return obj.print_object(s);
void set_by_val(const std::string &name, T value)
Set attribute value.
void set_by_ref(const std::string &name, T &value)
Set attribute value.
void set_enum(const std::string &name, const std::string &value)
Set attribute enumeration value.
The base class for any generated DAL object.
std::mutex m_mutex
Used to protect changes of DAL object.
ConfigObject p_obj
Config object used by given template object.
void check_init() const
Check and initialize object if necessary.
DalRegistry: A registry of DalObjects It provides a single interface to create, cache and manage DalO...
Generic configuration exception.
std::string m_controller_log_level
static const std::string & __get_connectivity_service_str() noexcept
static const std::string s_connectivity_service
std::vector< const dunedaq::confmodel::ResourceBase * > m_disabled
uint32_t m_data_request_timeout_ms
void set_segment(const dunedaq::confmodel::Segment *value)
Set "segment" relationship value. List of configuration Segments that form this Session.
virtual ~Session() noexcept
std::vector< const dunedaq::confmodel::Application * > get_all_applications() const
void set_rte_script(const std::string &value)
Set "rte_script" attribute value. Path to a script for setting up the runtime environment for DAQ app...
const dunedaq::confmodel::OpMonURI * m_opmon_uri
void set_controller_log_level(const std::string &value)
Set "controller_log_level" attribute value. Log level to use for drunc controllers.
const dunedaq::confmodel::DetectorConfig * m_detector_configuration
void set_detector_configuration(const dunedaq::confmodel::DetectorConfig *value)
Set "detector_configuration" relationship value.
static const std::string & __get_rte_script_str() noexcept
void set_enabled(const std::set< const dunedaq::confmodel::Component * > &objs) const
std::vector< const dunedaq::confmodel::Application * > m_infrastructure_applications
void set_disabled(const std::vector< const dunedaq::confmodel::ResourceBase * > &value)
Set "disabled" relationship value. Resources that should not participate in the current run.
static const std::string & __get_log_path_str() noexcept
static const std::string & __get_segment_str() noexcept
static const std::string s_data_request_timeout_ms
std::string m_description
void set_environment(const std::vector< const dunedaq::confmodel::VariableBase * > &value)
Set "environment" relationship value. Define process environment for any application run in given ses...
dunedaq::confmodel::DisabledComponents m_disabled_components
const std::vector< const dunedaq::confmodel::Application * > & get_infrastructure_applications() const
Get "infrastructure_applications" relationship value.
static const std::string & __get_disabled_str() noexcept
static const std::string & __get_detector_configuration_str() noexcept
uint32_t get_data_rate_slowdown_factor() const
Get "data_rate_slowdown_factor" attribute value. "Factor by which to suppress data generation.
static const std::string s_rte_script
friend class conffwk::DalFactory
std::vector< const dunedaq::confmodel::Application * > get_enabled_applications() const
void set_data_request_timeout_ms(uint32_t value)
Set "data_request_timeout_ms" attribute value. The baseline data request timeout that will be used by...
static const std::string & __get_data_request_timeout_ms_str() noexcept
static const std::string s_data_rate_slowdown_factor
Session(conffwk::DalRegistry &db, const conffwk::ConfigObject &obj) noexcept
const dunedaq::confmodel::Segment * get_segment() const
Get "segment" relationship value. List of configuration Segments that form this Session.
const std::string & get_description() const
Get "description" attribute value. A description of the session.
void set_infrastructure_applications(const std::vector< const dunedaq::confmodel::Application * > &value)
Set "infrastructure_applications" relationship value.
virtual std::vector< const dunedaq::conffwk::DalObject * > get(const std::string &name, bool upcast_unregistered=true) const
Get values of relationships and results of some algorithms as a vector of dunedaq::conffwk::DalObject...
uint32_t get_data_request_timeout_ms() const
Get "data_request_timeout_ms" attribute value. The baseline data request timeout that will be used by...
static const std::string & __get_infrastructure_applications_str() noexcept
static const std::string & __get_opmon_uri_str() noexcept
static const std::string & __get_environment_str() noexcept
std::vector< const dunedaq::confmodel::VariableBase * > m_environment
friend class conffwk::DalObject
void set_opmon_uri(const dunedaq::confmodel::OpMonURI *value)
Set "opmon_uri" relationship value. Configuration for the OpMon facilities used across the session.
static const std::string s_infrastructure_applications
void set_disabled(const std::set< const dunedaq::confmodel::Component * > &objs) const
static const std::string s_description
const dunedaq::confmodel::DetectorConfig * get_detector_configuration() const
Get "detector_configuration" relationship value.
static const std::string s_segment
static const std::string s_disabled
virtual void init(bool init_children)
static const std::string & __get_data_rate_slowdown_factor_str() noexcept
void set_connectivity_service(const dunedaq::confmodel::ConnectivityService *value)
Set "connectivity_service" relationship value. Configuration for the Connectivity Service lookups.
const std::string & get_controller_log_level() const
Get "controller_log_level" attribute value. Log level to use for drunc controllers.
const dunedaq::confmodel::Segment * m_segment
static const std::string s_log_path
const std::vector< const dunedaq::confmodel::ResourceBase * > & get_disabled() const
Get "disabled" relationship value. Resources that should not participate in the current run.
static const std::string s_controller_log_level
static const std::string & __get_controller_log_level_str() noexcept
static const std::string s_environment
const std::vector< const dunedaq::confmodel::VariableBase * > & get_environment() const
Get "environment" relationship value. Define process environment for any application run in given ses...
const dunedaq::confmodel::ConnectivityService * m_connectivity_service
static const std::string s_opmon_uri
static const std::string & s_class_name
void set_data_rate_slowdown_factor(uint32_t value)
Set "data_rate_slowdown_factor" attribute value. "Factor by which to suppress data generation.
void set_description(const std::string &value)
Set "description" attribute value. A description of the session.
void set_log_path(const std::string &value)
Set "log_path" attribute value. Where the applications, controllers and infrastructure applications s...
const dunedaq::confmodel::ConnectivityService * get_connectivity_service() const
Get "connectivity_service" relationship value. Configuration for the Connectivity Service lookups.
static const std::string & __get_description_str() noexcept
static const std::string s_detector_configuration
const dunedaq::confmodel::OpMonURI * get_opmon_uri() const
Get "opmon_uri" relationship value. Configuration for the OpMon facilities used across the session.
uint32_t m_data_rate_slowdown_factor
const std::string & get_log_path() const
Get "log_path" attribute value. Where the applications, controllers and infrastructure applications s...
const std::string & get_rte_script() const
Get "rte_script" attribute value. Path to a script for setting up the runtime environment for DAQ app...
std::vector< constSession * >::const_iterator SessionIterator
std::ostream & operator<<(std::ostream &s, const ActionPlan &obj)
static const std::string ERROR
static const std::string CRITICAL
static const std::string INFO
static const std::string WARNING
static const std::string DEBUG