CMS 3D CMS Logo

L1CondDBPayloadWriter_cff.py
Go to the documentation of this file.
1 def initPayloadWriter( process,
2  outputDBConnect = 'sqlite_file:l1config.db',
3  outputDBAuth = '.',
4  tagBaseVec = [] ):
5  import FWCore.ParameterSet.Config as cms
6  from CondTools.L1Trigger.L1CondEnum_cfi import L1CondEnum
7 
8  if len( tagBaseVec ) == 0:
9  from CondTools.L1Trigger.L1UniformTags_cfi import initL1UniformTags
11  tagBaseVec = initL1UniformTags.tagBaseVec
12 
13  process.load('CondTools.L1Trigger.L1CondDBPayloadWriter_cfi')
14 
15  from CondCore.DBCommon.CondDBSetup_cfi import CondDBSetup
16  initPayloadWriter.outputDB = cms.Service("PoolDBOutputService",
17  CondDBSetup,
18  connect = cms.string(outputDBConnect),
19  toPut = cms.VPSet(cms.PSet(
20  record = cms.string("L1TriggerKeyListRcd"),
21  tag = cms.string("L1TriggerKeyList_" + tagBaseVec[ L1CondEnum.L1TriggerKeyList ]))
22  ))
23  initPayloadWriter.outputDB.DBParameters.authenticationPath = outputDBAuth
24  process.add_(initPayloadWriter.outputDB)
def initL1UniformTags(tagBase="IDEAL")
def initPayloadWriter(process, outputDBConnect='sqlite_file:l1config.db', outputDBAuth='.', tagBaseVec=[])