[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
branch master updated: evaluate: Builds inherit their priority from the
From: |
Ludovic Courtès |
Subject: |
branch master updated: evaluate: Builds inherit their priority from the spec. |
Date: |
Fri, 22 Sep 2023 05:25:12 -0400 |
This is an automated email from the git hooks/post-receive script.
civodul pushed a commit to branch master
in repository guix-cuirass.
The following commit(s) were added to refs/heads/master by this push:
new b97ea9d evaluate: Builds inherit their priority from the spec.
b97ea9d is described below
commit b97ea9d7379831c8a19af77ae10aaa8aaee137a6
Author: Ludovic Courtès <ludo@gnu.org>
AuthorDate: Fri Sep 22 11:21:29 2023 +0200
evaluate: Builds inherit their priority from the spec.
Previously, builds would all get the default priority, meaning that jobset
priority would effectively ignored when scheduling builds via
‘db-get-pending-build’.
* src/cuirass/scripts/evaluate.scm (user-alists->builds): Change
‘specification-name’ parameter to ‘spec’. Set the ‘priority’ field of
<build>.
(inferior-evaluation): Adjust call accordingly.
---
src/cuirass/scripts/evaluate.scm | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
diff --git a/src/cuirass/scripts/evaluate.scm b/src/cuirass/scripts/evaluate.scm
index 1245a3c..dd76f49 100644
--- a/src/cuirass/scripts/evaluate.scm
+++ b/src/cuirass/scripts/evaluate.scm
@@ -46,12 +46,13 @@ CHECKOUTS."
#:commit commit)))
checkouts))
-(define (user-alists->builds jobs specification-name evaluation-id)
- "Convert JOBS, the user-supplied list of job alists for SPECIFICATION-NAME
and
+(define (user-alists->builds jobs spec evaluation-id)
+ "Convert JOBS, the user-supplied list of job alists for SPEC and
EVALUATION-ID, into a list of <build> records."
(map (lambda (alist)
(build (evaluation-id evaluation-id)
- (specification-name specification-name)
+ (specification-name (specification-name spec))
+ (priority (specification-priority spec))
(job-name (assq-ref alist #:job-name))
(nix-name (assq-ref alist #:nix-name))
(system (assq-ref alist #:system))
@@ -101,9 +102,7 @@ Pass the BUILD, CHANNELS and SYSTEMS arguments to the
EVAL-PROC procedure."
;; EVAL-PROC returns a list of job alists: this has the advantage of
;; being serializable and immune to ABI and API changes. Here, convert
;; it to <build> records for internal consumption.
- (db-register-builds (user-alists->builds jobs
- (specification-name spec)
- eval-id)
+ (db-register-builds (user-alists->builds jobs spec eval-id)
spec))))
(define (channel-instances->profile instances)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- branch master updated: evaluate: Builds inherit their priority from the spec.,
Ludovic Courtès <=