diff options
Diffstat (limited to 'guix-build-coordinator/agent-messaging')
-rw-r--r-- | guix-build-coordinator/agent-messaging/http/server.scm | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/guix-build-coordinator/agent-messaging/http/server.scm b/guix-build-coordinator/agent-messaging/http/server.scm index 7bfc0b5..85ba0d4 100644 --- a/guix-build-coordinator/agent-messaging/http/server.scm +++ b/guix-build-coordinator/agent-messaging/http/server.scm @@ -137,13 +137,14 @@ INTERVAL (a time-duration object), otherwise does nothing and returns #f." build-coordinator chunked-request-channel output-hash-channel) + (define plain-metrics-registry + (make-metrics-registry)) + (define gc-metrics-updater - (get-gc-metrics-updater - (build-coordinator-metrics-registry build-coordinator))) + (get-gc-metrics-updater plain-metrics-registry)) - (define port-metrics-updater - (get-port-metrics-updater - (build-coordinator-metrics-registry build-coordinator))) + (define process-metrics-updater + (get-process-metrics-updater plain-metrics-registry)) (define thread-metric (make-gauge-metric @@ -157,7 +158,7 @@ INTERVAL (a time-duration object), otherwise does nothing and returns #f." (call-with-delay-logging gc-metrics-updater) (metric-set thread-metric (length (all-threads))) - (call-with-delay-logging port-metrics-updater) + (call-with-delay-logging process-metrics-updater) (call-with-delay-logging datastore-metrics-updater)) (with-exception-handler @@ -184,7 +185,8 @@ INTERVAL (a time-duration object), otherwise does nothing and returns #f." build-coordinator chunked-request-channel output-hash-channel - update-managed-metrics!))) + update-managed-metrics! + plain-metrics-registry))) #:host host #:port port)) #:unwind? #t)) @@ -614,7 +616,8 @@ INTERVAL (a time-duration object), otherwise does nothing and returns #f." build-coordinator chunked-request-channel output-hash-channel - update-managed-metrics!) + update-managed-metrics! + plain-metrics-registry) (define (authenticated? uuid request) (let* ((authorization-base64 (match (assq-ref (request-headers request) @@ -1015,6 +1018,8 @@ INTERVAL (a time-duration object), otherwise does nothing and returns #f." (lambda (port) (write-metrics (build-coordinator-metrics-registry build-coordinator) + port) + (write-metrics plain-metrics-registry port)))))) (_ (render-json |