15os.system (
'rm -f Catalog2.xml')
17from AthenaConfiguration.AllConfigFlags
import initConfigFlags
18from AthenaConfiguration.ComponentFactory
import CompFactory
21outputFileName =
"ROOTTREE:SimplePoolFile5.root"
22outputStreamName =
"ExampleMeta"
26flags = initConfigFlags()
28flags.addFlag(f
"Output.{outputStreamName}FileName", outputFileName)
29flags.Exec.MaxEvents = 10
30flags.Common.MsgSuppression =
False
31flags.Exec.DebugMessageComponents = [
"PoolSvc",
"AthenaPoolCnvSvc",
"AthenaPoolAddressProviderSvc",
"MetaDataSvc"]
35from AthenaConfiguration.MainServicesConfig
import MainServicesCfg
36acc = MainServicesCfg( flags )
38from xAODEventInfoCnv.xAODEventInfoCnvConfig
import EventInfoCnvAlgCfg
39acc.merge( EventInfoCnvAlgCfg( flags, disableBeamSpot=
True ) )
41from AthenaPoolExampleAlgorithms.AthenaPoolExampleConfig
import AthenaPoolExampleWriteCfg
42acc.merge( AthenaPoolExampleWriteCfg( flags, outputStreamName,
43 writeCatalog =
"file:Catalog2.xml",
44 disableEventTag = noTag ) )
47acc.addEventAlgo( CompFactory.AthPoolEx.WriteData(
"WriteData", OutputLevel = DEBUG) )
48acc.addEventAlgo( CompFactory.AthPoolEx.WriteCond(
"WriteCond",
49 DetStore = acc.getService(
"MetaDataStore"),
50 ConditionName =
"PedestalWriteData",
51 OutputLevel = DEBUG) )
53from OutputStreamAthenaPool.OutputStreamConfig
import OutputStreamCfg
54acc.merge( OutputStreamCfg( flags, outputStreamName, disableEventTag = noTag,
55 ItemList = [
"EventInfo#*",
"ExampleHitContainer#MyHits"],
56 MetadataItemList = [
"ExampleHitContainer#PedestalWriteData"],
61sc = acc.run(flags.Exec.MaxEvents)
62sys.exit(sc.isFailure())