aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--guix-data-service/web/server.scm44
1 files changed, 22 insertions, 22 deletions
diff --git a/guix-data-service/web/server.scm b/guix-data-service/web/server.scm
index d56066e..1be3ef4 100644
--- a/guix-data-service/web/server.scm
+++ b/guix-data-service/web/server.scm
@@ -101,7 +101,6 @@
(%guix-data-service-metrics-registry registry)
(let ((finished? (make-condition))
- (render-metrics (make-render-metrics registry))
(request-scheduler #f))
(call-with-sigint
(lambda ()
@@ -218,27 +217,28 @@ port. Also, the port used can be changed by passing the --port option.\n"
conn)))
request-scheduler)
- (run-server/patched
- (lambda (request body)
- (metric-increment requests-metric)
-
- (let ((reply (make-channel)))
- (spawn-fiber
- (lambda ()
- (call-with-values
- (lambda ()
- (handler request finished? body controller
- secret-key-base
- startup-completed
- render-metrics))
- (lambda vals
- (put-message reply vals))))
- request-scheduler
- #:parallel? #t)
-
- (apply values (get-message reply))))
- #:host host
- #:port port))
+ (let ((render-metrics (make-render-metrics registry)))
+ (run-server/patched
+ (lambda (request body)
+ (metric-increment requests-metric)
+
+ (let ((reply (make-channel)))
+ (spawn-fiber
+ (lambda ()
+ (call-with-values
+ (lambda ()
+ (handler request finished? body controller
+ secret-key-base
+ startup-completed
+ render-metrics))
+ (lambda vals
+ (put-message reply vals))))
+ request-scheduler
+ #:parallel? #t)
+
+ (apply values (get-message reply))))
+ #:host host
+ #:port port)))
#:unwind? #t)))
;; Guile sometimes just seems to stop listening on the port, so try