10 inputDBConnect =
'frontier://FrontierProd/CMS_COND_31X_L1T',
14 includeAllTags =
False,
15 includeRSTags =
False,
16 use30XTagList =
False,
17 applyESPrefer =
True ):
18 import FWCore.ParameterSet.Config
as cms
20 from CondTools.L1Trigger.L1CondEnum_cfi
import L1CondEnum
22 if len( tagBaseVec ) == 0:
23 if len( tagBase ) != 0:
24 from CondTools.L1Trigger.L1UniformTags_cfi
import initL1UniformTags
26 tagBaseVec = initL1UniformTags.tagBaseVec
28 from CondTools.L1Trigger.L1O2OTags_cfi
import initL1O2OTags
30 tagBaseVec = initL1O2OTags.tagBaseVec
32 process.l1conddb = cms.ESSource(
"PoolDBESSource",
34 connect = cms.string(inputDBConnect),
35 toGet = cms.VPSet(cms.PSet(
36 record = cms.string(
'L1TriggerKeyListRcd'),
37 tag = cms.string(
'L1TriggerKeyList_' + tagBaseVec[ L1CondEnum.L1TriggerKeyList ])
40 record = cms.string(
'L1TriggerKeyRcd'),
41 tag = cms.string(
'L1TriggerKey_' + tagBaseVec[ L1CondEnum.L1TriggerKey ])
44 process.l1conddb.DBParameters.authenticationPath = inputDBAuth
49 if includeAllTags ==
True:
50 if use30XTagList ==
True:
51 from CondTools.L1Trigger.L1SubsystemParams30X_cfi
import initL1Subsystems
53 from CondTools.L1Trigger.L1SubsystemParams_cfi
import initL1Subsystems
55 process.l1conddb.toGet.extend(initL1Subsystems.params.recordInfo)
56 elif includeRSTags ==
True:
57 from CondTools.L1Trigger.L1RSSubsystemParams_cfi
import initL1RSSubsystems
59 process.l1conddb.toGet.extend(initL1RSSubsystems.params.recordInfo)
61 if applyESPrefer ==
True:
62 process.es_prefer_l1conddb = cms.ESPrefer(
"PoolDBESSource",
"l1conddb")
def initCondDBSource(process, inputDBConnect='frontier://FrontierProd/CMS_COND_31X_L1T', inputDBAuth='.', tagBase="", tagBaseVec=[], includeAllTags=False, includeRSTags=False, use30XTagList=False, applyESPrefer=True)
def initL1Subsystems(tagBaseVec=[], objectKey='dummy')