Get statistics regarding job executions¶
Note
This is quite early-stage, likely to get a better interface in the future
At any point, you can look at the procrastinate_jobs table for information regarding
the success rate and the average number of retries of your jobs, but this doesn’t
help if you’re interested in time-related information, or if you want to search
for jobs based on the date of some events they went through.
For this, there’s another table, procrastinate_events, which contains rows pointing
to jobs in the procrastinate_jobs table, dates & times and events. Here’s the
definition of each event:
deferredThe job has been enqueued, will be executed by the workers later.
startedThe job was started by a worker.
deferred_for_retryThe job failed, but according to the retry strategy, it should be retried (see Define a retry strategy on a task).
failedThe job failed, and will not be retried.
succeededThe job succeeded.
cancelledThe job was waiting to be executed, but was ultimately placed to
failedorsucceeded, bypassing execution.scheduledThis is a special event. When the job is deferred, this is the date where it’s expected to run.