Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Steinhardt <psteinhardt@gitlab.com>2022-03-29 13:16:00 +0300
committerPatrick Steinhardt <psteinhardt@gitlab.com>2022-03-29 13:39:41 +0300
commit42439883376e6d96ef78afd7f29c6d80f7b12c2f (patch)
tree34e74ef3238877fcb473ceae5b9f7a2c929a5686
parenta70761f20e4313499f32526a6f43a8cf4b9c3505 (diff)
housekeeping: Use common prefix for logged stale data
The fields we use to log stale data counts do not have any prefix right now, which makes it hard to find all such related fields when inspecting our logs. Add a `stale_data` prefix to group together all such fields.
-rw-r--r--internal/git/housekeeping/clean_stale_data.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/git/housekeeping/clean_stale_data.go b/internal/git/housekeeping/clean_stale_data.go
index a1d3f5eff..664675935 100644
--- a/internal/git/housekeeping/clean_stale_data.go
+++ b/internal/git/housekeeping/clean_stale_data.go
@@ -57,7 +57,7 @@ func (m *RepositoryManager) CleanStaleData(ctx context.Context, repo *localrepo.
logEntry := myLogger(ctx)
for staleDataType, count := range staleDataByType {
- logEntry = logEntry.WithField(staleDataType, count)
+ logEntry = logEntry.WithField(fmt.Sprintf("stale_data.%s", staleDataType), count)
m.prunedFilesTotal.WithLabelValues(staleDataType).Add(float64(count))
}
logEntry.Info("removed files")