On 02/22/2013 04:32 PM, Gawlas, Julius wrote:
My colleague Dan DeFolo, pointed out that one could use tko_jobs for that, 
perhaps with something like that:

select max(finished_time) from tko_jobs where afe_job_id=my_job_id;

Is that reasonable approach to finding out when job ended?

Sorry for the delay, this week was just crazy... anyway, here is the query I use in scheduler_models:

scheduler/scheduler_models.py, L 1005:

        time_row = _db.execute("""
                   SELECT started_time, finished_time
                   FROM tko_jobs
                   WHERE afe_job_id = %s
                   """ % self.id)

So there you go, nice and easy.

Lucas

_______________________________________________
Autotest-kernel mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/autotest-kernel

Reply via email to