From cda9bce7f3e6bdc80a43efef43d9d7758c940a28 Mon Sep 17 00:00:00 2001 From: Damien De Paoli Date: Fri, 15 Jan 2021 16:58:55 +1100 Subject: [PATCH] just staring on this, it is not even reference anywhere --- pa_job_engine.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 pa_job_engine.py diff --git a/pa_job_engine.py b/pa_job_engine.py new file mode 100644 index 0000000..110bc67 --- /dev/null +++ b/pa_job_engine.py @@ -0,0 +1,19 @@ +### +# +# This file controls the 'external' job control engine, that (periodically # +# looks / somehow is pushed an event?) picks up new jobs, and processes them. +# +# It then stores the progress/status, etc. in job and joblog tables as needed +# via wrapper functions. +# +# The whole pa_job_engine is multi-threaded, and uses the database tables for +# state management and communication back to the pa web site +# +### + +class PA_JobEngine(db.Model): + __tablename__ = "pa_job_engine" + id = db.Column(db.Integer, db.Sequence('pa_job_engine_id_seq'), primary_key=True) + state db.Column(db.String) + num_jobs_active = db.Column(db.Integer) + num_jobs_complete = db.Column(db.Integer)