From 736b9319221319f24608e6fbe13ef9a97c2ca0b1 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Sat, 22 Oct 2022 09:48:05 +0100 Subject: Log when output files are renamed --- .../agent-messaging/http/server.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/guix-build-coordinator/agent-messaging/http/server.scm b/guix-build-coordinator/agent-messaging/http/server.scm index b2b9fd9..384e953 100644 --- a/guix-build-coordinator/agent-messaging/http/server.scm +++ b/guix-build-coordinator/agent-messaging/http/server.scm @@ -495,6 +495,10 @@ port. Also, the port used can be changed by passing the --port option.\n" ;; Compute the hash of the file (let ((hash (compute-hash tmp-output-file-name))) + (log-msg logger + 'DEBUG + "computed the hash of " tmp-output-file-name ", renaming") + (rename-file tmp-output-file-name output-file-name) hash)))) @@ -527,6 +531,11 @@ port. Also, the port used can be changed by passing the --port option.\n" (put-bytevector output-port body))) (let ((hash (compute-hash tmp-output-file-name))) + (log-msg logger + 'DEBUG + "computed the hash of " tmp-output-file-name + ", renaming") + (rename-file tmp-output-file-name output-file-name) hash)) @@ -655,6 +664,11 @@ port. Also, the port used can be changed by passing the --port option.\n" ;; Compute the hash of the file (let ((hash (compute-hash tmp-output-file-name))) + (log-msg logger + 'DEBUG + "computed the hash of " tmp-output-file-name + ", renaming") + (rename-file tmp-output-file-name output-file-name) hash)))) @@ -681,6 +695,11 @@ port. Also, the port used can be changed by passing the --port option.\n" (close-port output-port) (let ((hash (compute-hash tmp-output-file-name))) + (log-msg logger + 'DEBUG + "computed the hash of " tmp-output-file-name + ", renaming") + (rename-file tmp-output-file-name output-file-name) hash)) -- cgit v1.2.3