diff options
author | Christopher Baines <mail@cbaines.net> | 2024-04-26 09:46:10 +0100 |
---|---|---|
committer | Christopher Baines <mail@cbaines.net> | 2024-04-26 09:46:10 +0100 |
commit | 62010990032a87417b4e4358752d52407e5614a4 (patch) | |
tree | 628305abf9a82c57e1a68693f3c30f0365f6d643 /guix-data-service/web | |
parent | 824e731a5c0ebb6acc8eb118fda1fd2bfc367256 (diff) | |
download | data-service-62010990032a87417b4e4358752d52407e5614a4.tar data-service-62010990032a87417b4e4358752d52407e5614a4.tar.gz |
Instrument requests
Diffstat (limited to 'guix-data-service/web')
-rw-r--r-- | guix-data-service/web/server.scm | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/guix-data-service/web/server.scm b/guix-data-service/web/server.scm index 4f2a4a0..6e91809 100644 --- a/guix-data-service/web/server.scm +++ b/guix-data-service/web/server.scm @@ -165,7 +165,9 @@ conn)))) (let ((render-metrics - (make-render-metrics registry))) + (make-render-metrics registry)) + (requests-metric + (make-counter-metric registry "requests_total"))) (with-exception-handler (lambda (exn) @@ -181,6 +183,8 @@ port. Also, the port used can be changed by passing the --port option.\n" (lambda () (run-server/patched (lambda (request body) + (metric-increment requests-metric) + (handler request finished? body controller secret-key-base startup-completed |