From 633524379dbc87de061661177985c853ac0014db Mon Sep 17 00:00:00 2001 From: Abhishek Pandey Date: Fri, 6 Oct 2023 15:02:52 +0530 Subject: [PATCH] 1.20 --- src/go.mod | 2 +- src/internal/events/events.go | 22 +++++++++++----------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/go.mod b/src/go.mod index 68452b8cd..cce04b210 100644 --- a/src/go.mod +++ b/src/go.mod @@ -1,6 +1,6 @@ module github.com/alcionai/corso/src -go 1.21 +go 1.20 replace github.com/kopia/kopia => github.com/alcionai/kopia v0.12.2-0.20230822191057-17d4deff94a3 diff --git a/src/internal/events/events.go b/src/internal/events/events.go index f50781788..b6c82154b 100644 --- a/src/internal/events/events.go +++ b/src/internal/events/events.go @@ -267,18 +267,18 @@ func NewMetrics(ctx context.Context, w io.Writer) (context.Context, func()) { // it to dump metrics to the provided writer (which should be the logger). // Expectation is for users to call this in a goroutine. Any signal or close() on the stop chan // will exit the loop. -func dumpMetrics(ctx context.Context, stop <-chan struct{}, sig *metrics.InmemSignal) { - tock := time.NewTicker(reportInterval) +// func dumpMetrics(ctx context.Context, stop <-chan struct{}, sig *metrics.InmemSignal) { +// tock := time.NewTicker(reportInterval) - for { - select { - case <-tock.C: - signalDump(ctx) - case <-stop: - return - } - } -} +// for { +// select { +// case <-tock.C: +// signalDump(ctx) +// case <-stop: +// return +// } +// } +// } // Inc increments the given category by 1. func Inc(cat metricsCategory, keys ...string) {