diff options
author | Mathieu Othacehe <othacehe@gnu.org> | 2020-11-25 15:49:04 +0100 |
---|---|---|
committer | Mathieu Othacehe <othacehe@gnu.org> | 2020-11-25 16:49:22 +0100 |
commit | fd432b8e8f449d691773e96e7d90f44761e01aa3 (patch) | |
tree | 5d07b6ad8f04134104641bf757704414196d7328 /src/sql/upgrade-16.sql | |
parent | e0f97e475f6d9d832eb67b3576f2c43a0aff65b4 (diff) | |
download | cuirass-fd432b8e8f449d691773e96e7d90f44761e01aa3.tar cuirass-fd432b8e8f449d691773e96e7d90f44761e01aa3.tar.gz |
Use specification for periodic builds.
When the periodic argument is passed to a job, it will be registered only if
the time difference between the current time and the registration time of the
last build is greater than the specified period. Make sure that the last job
that is searched is part of the same specification.
* src/sql/upgrade-16.sql: New file.
* Makefile.am (dist_sql_DATA): Add it.
* src/schema.sql (Builds_job_name_timestamp): New index.
* src/cuirass/database.scm (db-get-time-since-previous-build): Add
"specification" argument,
(db-register-builds): pass it.
Diffstat (limited to 'src/sql/upgrade-16.sql')
-rw-r--r-- | src/sql/upgrade-16.sql | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/sql/upgrade-16.sql b/src/sql/upgrade-16.sql new file mode 100644 index 0000000..47d498c --- /dev/null +++ b/src/sql/upgrade-16.sql @@ -0,0 +1,5 @@ +BEGIN TRANSACTION; + +CREATE INDEX Builds_job_name_timestamp on Builds(job_name, timestamp); + +COMMIT; |