CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
o2o_db_cfgmap.DbManagerDAQ Class Reference
Inheritance diagram for o2o_db_cfgmap.DbManagerDAQ:

Public Member Functions

def __init__ (self, db, authPath=None)
 
def update_hashmap (self, input_path)
 

Public Attributes

 ConfigToPayloadMap
 
 ConfigToPayloadMapSqlite
 

Detailed Description

Definition at line 22 of file o2o_db_cfgmap.py.

Constructor & Destructor Documentation

◆ __init__()

def o2o_db_cfgmap.DbManagerDAQ.__init__ (   self,
  db,
  authPath = None 
)

Definition at line 23 of file o2o_db_cfgmap.py.

23  def __init__(self, db, authPath=None):
24  DbManager.__init__(self, db, authPath)
25  self.ConfigToPayloadMap = make_dbtype(ConfigToPayloadMapDef, self.schema)
26  if self.schema:
27  self.ConfigToPayloadMapSqlite = make_dbtype(ConfigToPayloadMapDef, schema=None)
28  else:
29  self.ConfigToPayloadMapSqlite = self.ConfigToPayloadMap
30 
def __init__(self, dataset, job_number, job_id, job_name, isDA, isMC, applyBOWS, applyEXTRACOND, extraconditions, runboundary, lumilist, intlumi, maxevents, gt, allFromGT, alignmentDB, alignmentTAG, apeDB, apeTAG, bowDB, bowTAG, vertextype, tracktype, refittertype, ttrhtype, applyruncontrol, ptcut, CMSSW_dir, the_dir)
def make_dbtype(backendName, schemaName, baseType)
Definition: conddblib.py:190

Member Function Documentation

◆ update_hashmap()

def o2o_db_cfgmap.DbManagerDAQ.update_hashmap (   self,
  input_path 
)

Definition at line 31 of file o2o_db_cfgmap.py.

References o2o_db_manager.DbManager.check_table(), o2o_db_cfgmap.DbManagerDAQ.ConfigToPayloadMap, o2o_db_cfgmap.DbManagerDAQ.ConfigToPayloadMapSqlite, ConnectionManager.connect(), RPCDBCom.connect(), conditionUploadTest.DB.connect(), l1t::DataManager.connect(), HCALConfigDB.connect(), TestBase.connect(), ReadBase.connect(), ShallowTree::BranchConnector.connect(), SimActivityRegistry.connect(), dqmservices::DQMMonitoringService.connect(), sim_act::Signaler< EndOfRun >.connect(), sim_act::Signaler< EndOfTrack >.connect(), sim_act::Signaler< BeginOfJob >.connect(), sim_act::Signaler< T >.connect(), sim_act::Signaler< G4Step >.connect(), sim_act::Signaler< EndOfEvent >.connect(), sim_act::Signaler< BeginOfRun >.connect(), sim_act::Signaler< BeginOfEvent >.connect(), sim_act::Signaler< BeginOfTrack >.connect(), sim_act::Signaler< DDDWorld >.connect(), L1TOMDSHelper.connect(), ShallowTree::TypedBranchConnector< T >.connect(), edm::signalslot::Signal< void(StreamID)>.connect(), edm::signalslot::Signal< void(ModuleDescription const &)>.connect(), edm::signalslot::Signal< void(eventsetup::ComponentDescription const *, eventsetup::EventSetupRecordKey const &, eventsetup::DataKey const &)>.connect(), edm::signalslot::Signal< void(eventsetup::EventSetupRecordKey const &, ESModuleCallingContext const &)>.connect(), edm::signalslot::Signal< void(IOVSyncValue const &)>.connect(), edm::signalslot::Signal< void(PathsAndConsumesOfModulesBase const &, ProcessContext const &)>.connect(), edm::signalslot::Signal< void(edm::BranchDescription const &)>.connect(), edm::signalslot::Signal< void(const edmplugin::PluginFactoryBase *)>.connect(), edm::signalslot::Signal< void(GlobalContext const &, TerminationOrigin)>.connect(), edm::signalslot::Signal< void(StreamContext const &, PathContext const &)>.connect(), edm::signalslot::Signal< void(GlobalContext const &)>.connect(), edm::signalslot::Signal< void(edm::StreamContext const &, edm::ModuleCallingContext const &)>.connect(), edm::signalslot::Signal< void(const edmplugin::SharedLibrary &)>.connect(), edm::signalslot::Signal< void(eventsetup::ComponentDescription const &)>.connect(), edm::signalslot::Signal< void(LuminosityBlockIndex)>.connect(), edm::signalslot::Signal< void(GlobalContext const &, ModuleCallingContext const &)>.connect(), edm::signalslot::Signal< void(service::SystemBounds const &)>.connect(), edm::signalslot::Signal< void(RunIndex)>.connect(), edm::signalslot::Signal< void(StreamContext const &, ModuleCallingContext const &)>.connect(), edm::signalslot::Signal< void(StreamContext const &)>.connect(), edm::signalslot::Signal< void(std::string const &)>.connect(), edm::signalslot::Signal< void()>.connect(), edm::signalslot::Signal< void(const std::string &, const std::string &)>.connect(), edm::signalslot::Signal< T >.connect(), edm::signalslot::Signal< void(StreamContext const &, PathContext const &, HLTPathStatus const &)>.connect(), edm::signalslot::Signal< void(const std::filesystem::path &)>.connect(), edm::signalslot::Signal< void(TerminationOrigin)>.connect(), edm::signalslot::Signal< void(StreamContext const &, TerminationOrigin)>.connect(), edm::signalslot::Signal< void(const std::string &, const edmplugin::PluginInfo &)>.connect(), o2o_db_manager.DbManager.connect(), edm::ServiceToken.connect(), DDTOBRodAlgo.connect, GlobalTag.GlobalTag.connect(), PFCandConnector.connect(), confdbOfflineConverter.OfflineConverter.connect, SiStripGainFromCalibTree.connect(), edm::signalslot::ObsoleteSignal< T >.connect(), o2olib.O2OJobMgr.connect(), edm::serviceregistry::ServicesManager.connect(), conddb_version_mgr.conddb_tool.connect(), l1t::OMDSReader.connect(), cond::OMSService.connect(), edm::ActivityRegistry.connect(), and first.

31  def update_hashmap(self, input_path):
32  if not os.path.exists(input_path):
33  logging.info('No config-to-payload map file at %s. Skipping.' % input_path)
34  return
35  session = self.connect('sqlite:///%s' % input_path)
36  entry = session.query(self.ConfigToPayloadMapSqlite).first()
37  if entry:
38  self.check_table(ConfigToPayloadMapDef, self.ConfigToPayloadMap)
39  destSession = self.connect()
40  cfgmap = self.ConfigToPayloadMap(config_hash=entry.config_hash,
41  payload_hash=entry.payload_hash,
42  payload_type=entry.payload_type,
43  config_string=entry.config_string,
44  insertion_time=entry.insertion_time)
45  destSession.add(cfgmap)
46  destSession.commit()
47  logging.info('Updated config-to-payload map for %s' % cfgmap.payload_type)
48  logging.info('... config_hash = %s, payload_hash = %s' % (cfgmap.config_hash, cfgmap.payload_hash))
49  else:
50  raise RuntimeError('No entry found in config-to-payload map file %s' % input_path)

Member Data Documentation

◆ ConfigToPayloadMap

o2o_db_cfgmap.DbManagerDAQ.ConfigToPayloadMap

Definition at line 25 of file o2o_db_cfgmap.py.

Referenced by o2o_db_cfgmap.DbManagerDAQ.update_hashmap().

◆ ConfigToPayloadMapSqlite

o2o_db_cfgmap.DbManagerDAQ.ConfigToPayloadMapSqlite

Definition at line 27 of file o2o_db_cfgmap.py.

Referenced by o2o_db_cfgmap.DbManagerDAQ.update_hashmap().