aboutsummaryrefslogtreecommitdiff
path: root/guix-build-coordinator/datastore/sqlite.scm
diff options
context:
space:
mode:
Diffstat (limited to 'guix-build-coordinator/datastore/sqlite.scm')
-rw-r--r--guix-build-coordinator/datastore/sqlite.scm16
1 files changed, 13 insertions, 3 deletions
diff --git a/guix-build-coordinator/datastore/sqlite.scm b/guix-build-coordinator/datastore/sqlite.scm
index 4251f75..5ed70ac 100644
--- a/guix-build-coordinator/datastore/sqlite.scm
+++ b/guix-build-coordinator/datastore/sqlite.scm
@@ -612,8 +612,14 @@ VALUES "
build-id
agent-id)
- (call-with-worker-thread
- (slot-ref datastore 'worker-writer-thread-channel)
+ (define (handle-inserting-unprocessed-hook-event db build-id agent-id)
+ (insert-unprocessed-hook-event
+ db
+ "build-started"
+ (list build-id agent-id)))
+
+ (datastore-call-with-transaction
+ datastore
(lambda (db)
(sqlite-exec
db
@@ -625,7 +631,11 @@ INSERT INTO build_starts (
build-id "', '"
agent-id "', "
"datetime('now')"
- ")")))))
+ ")"))
+
+ (handle-inserting-unprocessed-hook-event db build-id agent-id)))
+
+ #t)
(define-method (datastore-find-build-starts
(datastore <sqlite-datastore>)