tdaq-develop-2025-02-12
|
<virtual so future plugins can inherit from multiple table base classes More...
#include <otsdaq/TablePlugins/ARTDAQTableBase/ARTDAQTableBase.h>
Classes | |
struct | ARTDAQInfo |
struct | ColARTDAQDaq |
ARTDAQ DAQ Column names. More... | |
struct | ColARTDAQDaqParameter |
ARTDAQ DAQ Parameter Column names. More... | |
struct | ColARTDAQNotReader |
ARTDAQ Builder/Logger/Dispatcher Column names. More... | |
struct | ColARTDAQReader |
ARTDAQ Reader Column names. More... | |
struct | ColARTDAQSubsystem |
ARTDAQ Subsystem Column names. More... | |
struct | ColARTDAQSupervisor |
ARTDAQ Supervisor Column names. More... | |
struct | ProcessInfo |
struct | ProcessTypes |
struct | SubsystemInfo |
Public Member Functions | |
ARTDAQTableBase () | |
ARTDAQTableBase (std::string tableName, std::string *accumulatedExceptions=0) | |
![]() | |
TableBase (bool specialTable, const std::string &specialTableName) | |
TableBase (const std::string &tableName, std::string *accumulatedExceptions=0) | |
virtual | ~TableBase (void) |
virtual void | init (ConfigurationManager *configManager) |
Methods. | |
void | destroy (void) |
void | reset (bool keepTemporaryVersions=false) |
void | deactivate (void) |
bool | isActive (void) |
isActive | |
void | print (std::ostream &out=std::cout) const |
always prints active view | |
std::string | getTypeId (void) |
void | setupMockupView (TableVersion version) |
void | changeVersionAndActivateView (TableVersion temporaryVersion, TableVersion version) |
bool | isStored (const TableVersion &version) const |
bool | eraseView (TableVersion version) |
void | trimCache (unsigned int trimSize=-1) |
void | trimTemporary (TableVersion targetVersion=TableVersion()) |
TableVersion | checkForDuplicate (TableVersion needleVersion, TableVersion ignoreVersion=TableVersion()) const |
bool | diffTwoVersions (TableVersion v1, TableVersion v2, std::stringstream *diffReport=0, std::map< std::string, std::vector< std::string >> *v1ModifiedRecords=0) const |
const std::string & | getTableName (void) const |
Getters. | |
const std::string & | getTableDescription (void) const |
std::set< TableVersion > | getStoredVersions (void) const |
const TableView & | getView (TableVersion version=TableVersion(TableVersion::INVALID)) const |
TableView * | getViewP (TableVersion version=TableVersion(TableVersion::INVALID)) |
TableView * | getMockupViewP (void) |
const TableVersion & | getViewVersion (void) const |
always the active one | |
TableView * | getTemporaryView (TableVersion temporaryVersion) |
TableVersion | getNextTemporaryVersion (void) const |
TableVersion | getNextVersion (void) const |
virtual std::string | getStructureStatusAsJSON (ConfigurationManager *configManager) const |
void | setTableName (const std::string &tableName) |
Setters. | |
void | setTableDescription (const std::string &tableDescription) |
bool | setActiveView (TableVersion version) |
TableVersion | copyView (const TableView &sourceView, TableVersion destinationVersion, const std::string &author, bool looseColumnMatching=false) |
TableVersion | mergeViews (const TableView &sourceViewA, const TableView &sourceViewB, TableVersion destinationVersion, const std::string &author, const std::string &mergeApproach, std::map< std::pair< std::string, std::string >, std::string > &uidConversionMap, std::map< std::pair< std::string, std::pair< std::string, std::string > >, std::string > &groupidConversionMap, bool fillRecordConversionMaps, bool applyRecordConversionMaps, bool generateUniqueDataColumns=false, std::stringstream *mergeRepoert=nullptr) |
TableVersion | createTemporaryView (TableVersion sourceViewVersion=TableVersion(), TableVersion destTemporaryViewVersion=TableVersion::getNextTemporaryVersion()) |
source of -1, from MockUp, else from valid view version More... | |
bool | latestAndMockupColumnNumberMismatch (void) const |
unsigned int | getNumberOfStoredViews (void) const |
Static Public Member Functions | |
static const std::string & | getTypeString (ARTDAQAppType type) |
static std::string | getFHICLFilename (ARTDAQAppType type, const std::string &name) |
static std::string | getFlatFHICLFilename (ARTDAQAppType type, const std::string &name) |
static void | flattenFHICL (ARTDAQAppType type, const std::string &name) |
static void | insertParameters (std::ostream &out, std::string &tabStr, std::string &commentStr, ConfigurationTree parameterLink, const std::string ¶meterPreamble, bool onlyInsertAtTableParameters=false, bool includeAtTableParameters=false) |
static std::string | insertModuleType (std::ostream &out, std::string &tabStr, std::string &commentStr, ConfigurationTree moduleTypeNode) |
static void | insertMetricsBlock (std::ostream &out, std::string &tabStr, std::string &commentStr, ConfigurationTree daqNode) |
insertMetricsBlock | |
static void | insertArtProcessBlock (std::ostream &out, std::string &tabStr, std::string &commentStr, ConfigurationTree art, ConfigurationTree subsystemLink=ConfigurationTree(), size_t routingTimeoutMs=DEFAULT_ROUTING_TIMEOUT_MS, size_t routingRetryCount=DEFAULT_ROUTING_RETRY_COUNT) |
static void | outputBoardReaderFHICL (const ConfigurationTree &boardReaderNode, size_t maxFragmentSizeBytes=DEFAULT_MAX_FRAGMENT_SIZE, size_t routingTimeoutMs=DEFAULT_ROUTING_TIMEOUT_MS, size_t routingRetryCount=DEFAULT_ROUTING_RETRY_COUNT) |
static void | outputDataReceiverFHICL (const ConfigurationTree &receiverNode, ARTDAQAppType appType, size_t maxFragmentSizeBytes=DEFAULT_MAX_FRAGMENT_SIZE, size_t routingTimeoutMs=DEFAULT_ROUTING_TIMEOUT_MS, size_t routingRetryCount=DEFAULT_ROUTING_RETRY_COUNT) |
static void | outputRoutingManagerFHICL (const ConfigurationTree &routingManagerNode, size_t routingTimeoutMs=DEFAULT_ROUTING_TIMEOUT_MS, size_t routingRetryCount=DEFAULT_ROUTING_RETRY_COUNT) |
static void | outputOnlineMonitorFHICL (const ConfigurationTree &onlineMonitorNode) |
static bool | isARTDAQEnabled (const ConfigurationManager *cfgMgr) |
isARTDAQEnabled | |
static const ARTDAQInfo & | extractARTDAQInfo (ConfigurationTree artdaqSupervisorNode, bool getStatusFalseNodes=false, bool doWriteFHiCL=false, size_t maxFragmentSizeBytes=DEFAULT_MAX_FRAGMENT_SIZE, size_t routingTimeoutMs=DEFAULT_ROUTING_TIMEOUT_MS, size_t routingRetryCount=DEFAULT_ROUTING_RETRY_COUNT, ProgressBar *progressBar=0) |
static const ARTDAQInfo & | getARTDAQSystem (ConfigurationManagerRW *cfgMgr, std::map< std::string, std::map< std::string, std::vector< std::string >>> &nodeTypeToObjectMap, std::map< std::string, std::string > &subsystemObjectMap, std::vector< std::string > &artdaqSupervisoInfo) |
static void | setAndActivateARTDAQSystem (ConfigurationManagerRW *cfgMgr, const std::map< std::string, std::map< std::string, std::vector< std::string >>> &nodeTypeToObjectMap, const std::map< std::string, std::string > &subsystemObjectMap) |
![]() | |
static std::string | convertToCaps (std::string &str, bool isConfigName=false) |
Static Public Attributes | |
static const std::string | ARTDAQ_FCL_PATH = std::string(__ENV__("USER_DATA")) + "/" + "ARTDAQConfigurations/" |
static const std::string | ARTDAQ_SUPERVISOR_CLASS = "ots::ARTDAQSupervisor" |
static const std::string | ARTDAQ_SUPERVISOR_TABLE = "ARTDAQSupervisorTable" |
static const std::string | ARTDAQ_READER_TABLE = "ARTDAQBoardReaderTable" |
static const std::string | ARTDAQ_BUILDER_TABLE = "ARTDAQEventBuilderTable" |
static const std::string | ARTDAQ_LOGGER_TABLE = "ARTDAQDataLoggerTable" |
static const std::string | ARTDAQ_DISPATCHER_TABLE = "ARTDAQDispatcherTable" |
static const std::string | ARTDAQ_MONITOR_TABLE = "ARTDAQMonitorTable" |
static const std::string | ARTDAQ_ROUTER_TABLE = "ARTDAQRoutingManagerTable" |
static const std::string | ARTDAQ_SUBSYSTEM_TABLE = "ARTDAQSubsystemTable" |
static const std::string | ARTDAQ_DAQ_TABLE = "ARTDAQDaqTable" |
static const std::string | ARTDAQ_DAQ_PARAMETER_TABLE = "ARTDAQDaqParameterTable" |
static const std::string | ARTDAQ_TYPE_TABLE_HOSTNAME = "ExecutionHostname" |
static const std::string | ARTDAQ_TYPE_TABLE_ALLOWED_PROCESSORS = "AllowedProcessors" |
static const std::string | ARTDAQ_TYPE_TABLE_SUBSYSTEM_LINK = "SubsystemLink" |
static const std::string | ARTDAQ_TYPE_TABLE_SUBSYSTEM_LINK_UID = "SubsystemLinkUID" |
static const int | NULL_SUBSYSTEM_DESTINATION = 0 |
static const std::string | NULL_SUBSYSTEM_DESTINATION_LABEL = "nullDestinationSubsystem" |
static struct ots::ARTDAQTableBase::ProcessTypes | processTypes_ |
Note!!!! processTypes_ must be instantiate after the static artdaq table names (to construct map in constructor in .h) | |
static struct ots::ARTDAQTableBase::ColARTDAQSupervisor | colARTDAQSupervisor_ |
static struct ots::ARTDAQTableBase::ColARTDAQSubsystem | colARTDAQSubsystem_ |
static struct ots::ARTDAQTableBase::ColARTDAQReader | colARTDAQReader_ |
static struct ots::ARTDAQTableBase::ColARTDAQNotReader | colARTDAQNotReader_ |
static struct ots::ARTDAQTableBase::ColARTDAQDaq | colARTDAQDaq_ |
static struct ots::ARTDAQTableBase::ColARTDAQDaqParameter | colARTDAQDaqParameter_ |
![]() | |
static const std::string | GROUP_CACHE_PREPEND = "GroupCache_" |
static const std::string | JSON_DOC_PREPEND = "JSONDoc_" |
Additional Inherited Members | |
![]() | |
const unsigned int | MAX_VIEWS_IN_CACHE |
![]() | |
std::string | tableName_ |
std::string | tableDescription_ |
TableView * | activeTableView_ |
TableView | mockupTableView_ |
std::map< TableVersion, TableView > | tableViews_ |
<virtual so future plugins can inherit from multiple table base classes
Definition at line 18 of file ARTDAQTableBase.h.
ARTDAQTableBase::ARTDAQTableBase | ( | void | ) |
ARTDAQTableBase Default constructor should never be used because table type is lost
Definition at line 96 of file ARTDAQTableBase.cc.
ARTDAQTableBase::ARTDAQTableBase | ( | std::string | tableName, |
std::string * | accumulatedExceptions = 0 |
||
) |
TableBase If a valid string pointer is passed in accumulatedExceptions then allowIllegalColumns is set for InfoReader If accumulatedExceptions pointer = 0, then illegal columns throw std::runtime_error exception
Definition at line 70 of file ARTDAQTableBase.cc.
|
static |
getARTDAQSystem
static function to retrive the active ARTDAQ system configuration.
Subsystem map to destination subsystem name. Node properties: {status,hostname,subsystemName,(nodeArrString),(hostnameArrString),(hostnameFixedWidth)} artdaqSupervisoInfo: {name, status, context address, context port}
Definition at line 2235 of file ARTDAQTableBase.cc.
|
static |
insertArtProcessBlock Note: currently selfRank and selfPort are unused by artdaq fcl
Definition at line 1034 of file ARTDAQTableBase.cc.
|
static |
insertModuleType Inserts module type field, with consideration for @table::
Definition at line 284 of file ARTDAQTableBase.cc.
|
static |
insertParameters Inserts parameters in FHiCL outputs stream.
onlyInsertAtTableParameters allows @table:: parameters only,
so that calling code can do two passes (i.e. top of fcl block, @table:: only, and bottom of fcl block, ignore/skip @table:: as default behavior).
Definition at line 212 of file ARTDAQTableBase.cc.
|
static |
outputDataReceiverFHICL Note: currently selfRank and selfPort are unused by artdaq fcl
Definition at line 654 of file ARTDAQTableBase.cc.
|
static |
outputOnlineMonitorFHICL Note: currently selfRank and selfPort are unused by artdaq fcl
Definition at line 844 of file ARTDAQTableBase.cc.
|
static |
setAndActivateARTDAQSystem
static function to modify the active configuration based on
node object and subsystem object.
Subsystem map to destination subsystem name. Node properties: {originalName,status,hostname,subsystemName,(nodeArrString),(hostnameArrString),(hostnameFixedWidth)}
needArtdaqSupervisorParents
Definition at line 2867 of file ARTDAQTableBase.cc.