The Selector framework
To be able to perform event-level parallelism, PROOF needs to be in charge of the event-loop, i.e. the execution flow steering the job. This requires that the code to be executed must have a predefined, though flexible structure. In ROOT this is provided by the Selector framework, defined by the abstract class TSelector, which defines three logical steps:
- Begin, where the job definition (parameters, input data, outputs) is given; executed on the client and the workers;
- Process, where the actual job is done; called for each event, on the workers;
- Terminate, where the results are finally manipulated (fitted, visualized,...); called on the client and the workers.
Process is the part that can be parallelized for the class of problems addressed by PROOF, i.e. those embarassingly or ideally parallel.