13 A test for scheduling multiple sub-event contexts.
14 The main sequence has two steps of creating and running sub-events.
16 The ViewTester is an algorithm specifically designed to create sub-event
17 contexts, pass them to the scheduler, and report on the current context.
19 Seven instances of ViewTester are used as follows:
20 - Algorithm A1 creates two sub-event contexts
21 - Algorithms A2 and A3 run within the sub-event contexts
22 - Algorithm A4 creates two more sub-event contexts
23 - Algorithms A5 and A6 run within the new sub-event contexts
24 - Algorithm A7 runs in the whole event context, after the sub-events
28 from Configurables
import (
30 AvalancheSchedulerSvc,
52 whiteboard = HiveWhiteBoard(
"EventDataSvc", EventSlots=evtslots)
60 slimeventloopmgr = HiveSlimEventLoopMgr(
61 SchedulerName=
"AvalancheSchedulerSvc", OutputLevel=DEBUG
71 scheduler = AvalancheSchedulerSvc(ThreadPoolSize=threads, OutputLevel=INFO)
77 AlgResourcePool(OutputLevel=DEBUG)
83 a1 = Test__ViewTester(
"A1")
84 a1.baseViewName =
"viewOne"
85 a1.viewNumber = viewsPerEvt
86 a1.viewNodeName =
"viewNodeOne"
88 a2 = Test__ViewTester(
"A2")
91 a3 = Test__ViewTester(
"A3")
94 a4 = Test__ViewTester(
"A4")
95 a4.baseViewName =
"viewTwo"
96 a4.viewNumber = viewsPerEvt
97 a4.viewNodeName =
"viewNodeTwo"
99 a5 = Test__ViewTester(
"A5")
102 a6 = Test__ViewTester(
"A6")
105 a7 = Test__ViewTester(
"A7")
108 for algo
in [a1, a2, a3, a4, a5, a6, a7]:
109 algo.Cardinality = cardinality
110 algo.OutputLevel = DEBUG
112 viewNodeOne = Gaudi__Sequencer(
113 "viewNodeOne", Members=[a2, a3], Sequential=
False, OutputLevel=VERBOSE
116 viewNodeTwo = Gaudi__Sequencer(
117 "viewNodeTwo", Members=[a5, a6], Sequential=
False, OutputLevel=VERBOSE
120 createViewSeq = Gaudi__Sequencer(
122 Members=[a1, viewNodeOne, a4, viewNodeTwo, a7],
134 EventLoop=slimeventloopmgr,
135 TopAlg=[createViewSeq],
136 MessageSvcType=
"InertMessageSvc",