]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commit
Add job expiration dates
authorZack Cerza <zack@redhat.com>
Mon, 1 Jul 2024 23:00:46 +0000 (17:00 -0600)
committerZack Cerza <zack@redhat.com>
Thu, 8 Aug 2024 00:05:15 +0000 (18:05 -0600)
commita5904616de4935b49747406205c7c8f484c933d5
treeeef74560844a4b27be836fb8e70a367851de7c98
parent674129db9df8481773848d25a6e70bed82f83224
Add job expiration dates

This feature has two parts:
* Specifying expiration dates when scheduling test runs
* A global maximum age

Expiration dates are provided by passing `--expire` to `teuthology-suite` with
a relative value like `1d` (one day), `1w` (one week), or an absolute value like
`1999-12-31_23:59:59`.

A new configuration item, `max_job_age`, is specified in seconds. This defaults
to two weeks.

When the dispatcher checks the queue for the next job to run, it will first
compare the job's `timestamp` value - which reflects the time the job was
scheduled. If more than `max_job_age` seconds have passed, the job is skipped
and marked dead. It next checks for an `expire` value; if that value is in the
past, the job is skipped and marked dead. Otherwise, it will be run as usual.

Signed-off-by: Zack Cerza <zack@redhat.com>
docs/siteconfig.rst
scripts/suite.py
teuthology/config.py
teuthology/dispatcher/__init__.py
teuthology/dispatcher/test/test_dispatcher.py
teuthology/suite/__init__.py
teuthology/suite/placeholder.py
teuthology/suite/run.py
teuthology/suite/test/test_placeholder.py
teuthology/suite/test/test_run_.py