diff options
author | Christopher Baines <mail@cbaines.net> | 2020-02-28 20:41:44 +0000 |
---|---|---|
committer | Christopher Baines <mail@cbaines.net> | 2020-02-28 20:41:44 +0000 |
commit | 185ba3685379c5f047c0f0804226e4f9c80d6d46 (patch) | |
tree | 47fba472f9e21b95990406a472b9bea0f666bff3 /guix-data-service | |
parent | f23223f16d8f532a60824d88a45deaa23ec43be2 (diff) | |
download | data-service-185ba3685379c5f047c0f0804226e4f9c80d6d46.tar data-service-185ba3685379c5f047c0f0804226e4f9c80d6d46.tar.gz |
Log the time spent in a locked section
Diffstat (limited to 'guix-data-service')
-rw-r--r-- | guix-data-service/jobs/load-new-guix-revision.scm | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/guix-data-service/jobs/load-new-guix-revision.scm b/guix-data-service/jobs/load-new-guix-revision.scm index 0f9cbba..3b5ce10 100644 --- a/guix-data-service/jobs/load-new-guix-revision.scm +++ b/guix-data-service/jobs/load-new-guix-revision.scm @@ -279,7 +279,11 @@ WHERE job_id = $1" (let ((time-taken (- (current-time) start-time))) (simple-format #t "debug: Finished aquiring lock ~A, took ~A seconds\n" lock time-taken)) - (f))))) + (let ((result (f))) + (let ((time-spent (- (current-time) start-time))) + (simple-format #t "debug: Releasing lock ~A, spent ~A seconds\n" + lock time-spent)) + result))))) (define (all-inferior-system-tests inf store) (define extract |