Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:52:05

0001 # 
0002 #
0003 # Read from xml and insert into database using
0004 # PopCon 
0005 #
0006 # This is a template, generate real test using
0007 #
0008 # sed 's/EcalIntercalibConstants/your-record/g' testTemplate.py > testyourrecord.py
0009 #
0010 # Stefano Argiro', $Id: testEcalIntercalibConstantsMC.py,v 1.1 2009/04/08 15:20:24 argiro Exp $
0011 #
0012 #
0013 
0014 import FWCore.ParameterSet.Config as cms
0015 
0016 process = cms.Process("TEST")
0017 
0018 process.MessageLogger = cms.Service("MessageLogger",
0019     cerr = cms.untracked.PSet(
0020         enable = cms.untracked.bool(False)
0021     ),
0022     cout = cms.untracked.PSet(
0023         enable = cms.untracked.bool(True),
0024         treshold = cms.untracked.string('INFO')
0025     )
0026 )
0027 
0028 process.load("CondCore.DBCommon.CondDBCommon_cfi")
0029 process.CondDBCommon.connect = cms.string('sqlite_file:testEcalIntercalibConstantsMC.db')
0030 process.CondDBCommon.DBParameters.authenticationPath = cms.untracked.string('/afs/cern.ch/cms/DB/conddb')
0031 
0032 process.source = cms.Source("EmptyIOVSource",
0033     timetype = cms.string('runnumber'),
0034     firstValue = cms.uint64(1),
0035     lastValue  = cms.uint64(2),
0036     interval = cms.uint64(1)
0037 )
0038 
0039 process.PoolDBOutputService = cms.Service("PoolDBOutputService",
0040     process.CondDBCommon,
0041     timetype = cms.untracked.string('runnumber'),
0042     toPut = cms.VPSet(cms.PSet(
0043         record = cms.string('EcalIntercalibConstantsMCRcd'),
0044         tag = cms.string('mytest')
0045          )),
0046     logconnect= cms.untracked.string('sqlite_file:logtestEcalIntercalibConstantsMC.db')                                     
0047 )
0048 
0049 process.mytest = cms.EDAnalyzer("EcalIntercalibConstantsMCAnalyzer",
0050     record = cms.string('EcalIntercalibConstantsMCRcd'),
0051     loggingOn= cms.untracked.bool(True),
0052     SinceAppendMode=cms.bool(True),
0053     Source=cms.PSet(
0054     xmlFile = cms.untracked.string('/tmp/EcalIntercalibConstantsMC.xml'),
0055     since = cms.untracked.int64(3)
0056     )                            
0057 )
0058 
0059 process.p = cms.Path(process.mytest)
0060 
0061 
0062 
0063