The library consists of three main parts.
The TaskScheduler stores tasks and schedules executions. For each task
there exists exactly one execution in the status planned or running. If
the task will only one time it only get one execution at all. For recurring
tasks a new execution will be generated when the old one is completed or
failed.
Each task consists of:
uuid: unique identifierhandlerClass: class-name of the handler which will be executed for this taskworkload: the workload will be passed to the handlerinterval: for recurring tasks this fields contains a cron-expressionfirstExecution: the earliest possible executionlastExecution: the latest possible execution
The TaskRunner takes the planned executions and executes the Handler
with the workload of the task.
The Handler implements the domain-logic for a task. The library implements
a Factory which uses Reflection to create a new instance for the
handlerClass of the task.
Note
The :doc:`symfony` uses tagged-services to find available Handler.