Files
photoassistant/pa_job_engine.py

20 lines
688 B
Python

###
#
# 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)