Timeout when trying to process build events

As if they relate to derivations that are currently being inserted, they'll
have to wait until the job is processed.
This commit is contained in:
Christopher Baines 2024-09-03 13:38:56 +01:00
parent fd7b0a341d
commit d73d20c985

View file

@ -20,6 +20,7 @@
#:use-module (ice-9 match) #:use-module (ice-9 match)
#:use-module (rnrs bytevectors) #:use-module (rnrs bytevectors)
#:use-module (json) #:use-module (json)
#:use-module (squee)
#:use-module (fibers) #:use-module (fibers)
#:use-module (prometheus) #:use-module (prometheus)
#:use-module (guix-data-service utils) #:use-module (guix-data-service utils)
@ -218,6 +219,8 @@
(with-postgresql-transaction (with-postgresql-transaction
conn conn
(lambda (conn) (lambda (conn)
(exec-query conn "SET LOCAL lock_timeout = '5s';")
(handle-derivation-events (handle-derivation-events
conn conn
filtered-items)))))) filtered-items))))))