mirror of
https://framagit.org/framasoft/framaspace/argos.git
synced 2025-04-28 09:52:38 +02:00
845 B
845 B
On service start.
- Read the job definitions file and populate the database.
- From the job definition, create a list of tasks to execute.
- From time to time (?) clean the db.
On configuration changes :
- Find and tombstone the JobDefinitions that are not useful anymore.
- Cascade delete the child tasks that are planned. Tombstone them as wel.
On worker demand :
- Find the tasks for which :
- last_check is not defined
- OR last_check + max_timedelta > datetime.now()
- AND selected_by not defined.
- Mark these tasks as selected by the current worker, on the current date.
From time to time:
- Check for stalled tasks (datetime.now() - selected_at) > MAX_WORKER_TIME. Remove the lock.
On the worker side
Hey, I'm XX, give me some work. OK, this is done, here are the results for Task: response.