From a448b229a86af51b2b1ea4074362e0a4be91c7e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Magiera?= Date: Fri, 27 May 2022 19:43:06 +0200 Subject: [PATCH] fix: worker: don't log noraml storage stat calls --- extern/sector-storage/stores/local.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/extern/sector-storage/stores/local.go b/extern/sector-storage/stores/local.go index 4a8c4e1b3a8..1f81d5bd0e9 100644 --- a/extern/sector-storage/stores/local.go +++ b/extern/sector-storage/stores/local.go @@ -157,7 +157,9 @@ func (p *path) stat(ls LocalStorage) (fsutil.FsStat, error) { } } - log.Infow("storage stat", "took", time.Now().Sub(start), "reservations", len(p.reservations)) + if time.Now().Sub(start) > 5*time.Second { + log.Warnw("slow storage stat", "took", time.Now().Sub(start), "reservations", len(p.reservations)) + } return stat, err }