commit dabf2c114669d037131d865e8ea78cdcd5b44d53
parent a201ebe738c30b2dae942ef665612d3ce44a7f80
Author: Joel-Haeberli <haebu@rubigen.ch>
Date: Mon, 3 Jun 2024 17:33:43 +0200
fix: enhance logging
Diffstat:
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/c2ec/proc-transfer.go b/c2ec/proc-transfer.go
@@ -132,7 +132,9 @@ func executePendingTransfers(errs chan error, lastlog time.Time) {
return
}
- LogInfo("proc-transfer", fmt.Sprintf("found %d pending transfers", len(transfers)))
+ if lastlog.Before(time.Now().Add(time.Second * -30)) {
+ LogInfo("proc-transfer", fmt.Sprintf("found %d pending transfers", len(transfers)))
+ }
for _, t := range transfers {
shouldRetry := ShouldStartRetry(time.Unix(t.TransferTs, 0), int(t.Retries), MAX_TRANSFER_BACKOFF_MS)