aboutsummaryrefslogtreecommitdiff
path: root/guix-data-service/web/controller.scm
diff options
context:
space:
mode:
Diffstat (limited to 'guix-data-service/web/controller.scm')
-rw-r--r--guix-data-service/web/controller.scm18
1 files changed, 10 insertions, 8 deletions
diff --git a/guix-data-service/web/controller.scm b/guix-data-service/web/controller.scm
index d23c2f3..cdf2318 100644
--- a/guix-data-service/web/controller.scm
+++ b/guix-data-service/web/controller.scm
@@ -35,6 +35,8 @@
#:use-module (texinfo html)
#:use-module (squee)
#:use-module (json)
+ #:use-module (knots parallelism)
+ #:use-module (knots resource-pool)
#:use-module (prometheus)
#:use-module (guix-data-service utils)
#:use-module (guix-data-service config)
@@ -234,7 +236,7 @@
#:always-rollback? #t))
(lambda ()
- (letpar& ((metric-values
+ (fibers-let ((metric-values
(with-exception-handler
(lambda (exn)
(simple-format
@@ -456,12 +458,12 @@
(write-metrics registry port))))))))
(define (render-derivation derivation-file-name)
- (letpar& ((derivation
+ (fibers-let ((derivation
(with-resource-from-pool (connection-pool) conn
(select-derivation-by-file-name conn derivation-file-name))))
(if derivation
- (letpar& ((derivation-inputs
+ (fibers-let ((derivation-inputs
(with-resource-from-pool (connection-pool) conn
(select-derivation-inputs-by-derivation-id
conn
@@ -495,7 +497,7 @@
(select-derivation-by-file-name conn
derivation-file-name))))
(if derivation
- (letpar& ((derivation-inputs
+ (fibers-let ((derivation-inputs
(with-resource-from-pool (connection-pool) conn
(select-derivation-inputs-by-derivation-id
conn
@@ -551,7 +553,7 @@
(select-derivation-by-file-name conn
derivation-file-name))))
(if derivation
- (letpar& ((derivation-inputs
+ (fibers-let ((derivation-inputs
(with-resource-from-pool (connection-pool) conn
(select-derivation-inputs-by-derivation-id
conn
@@ -596,7 +598,7 @@
#:sxml (view-narinfos narinfos)))))
(define (render-store-item filename)
- (letpar& ((derivation
+ (fibers-let ((derivation
(with-resource-from-pool (connection-pool) conn
(select-derivation-by-output-filename conn filename))))
(match derivation
@@ -619,7 +621,7 @@
filename)))
#:extra-headers http-headers-for-unchanging-content))))
(derivations
- (letpar& ((nars
+ (fibers-let ((nars
(with-resource-from-pool (connection-pool) conn
(select-nars-for-output conn filename)))
(builds
@@ -656,7 +658,7 @@
conn
filename))))))))))
(derivations
- (letpar& ((nars
+ (fibers-let ((nars
(with-resource-from-pool (connection-pool) conn
(select-nars-for-output conn filename))))
(render-json