From 48a72eb21ebe7bfcdd56d484b12ba99c2aec2773 Mon Sep 17 00:00:00 2001 From: Tim Vaillancourt Date: Wed, 11 Dec 2024 00:18:26 +0100 Subject: [PATCH] reset op start time Signed-off-by: Tim Vaillancourt --- go/vt/topo/stats_conn.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/go/vt/topo/stats_conn.go b/go/vt/topo/stats_conn.go index 89831596ea4..65c2b8b479a 100644 --- a/go/vt/topo/stats_conn.go +++ b/go/vt/topo/stats_conn.go @@ -75,6 +75,7 @@ func (st *StatsConn) ListDir(ctx context.Context, dirPath string, full bool) ([] } defer st.readSem.Release(1) topoStatsConnReadWaitTimings.Record(statsKey, startTime) + startTime = time.Now() // reset defer topoStatsConnTimings.Record(statsKey, startTime) res, err := st.conn.ListDir(ctx, dirPath, full) if err != nil { @@ -125,6 +126,7 @@ func (st *StatsConn) Get(ctx context.Context, filePath string) ([]byte, Version, } defer st.readSem.Release(1) topoStatsConnReadWaitTimings.Record(statsKey, startTime) + startTime = time.Now() // reset defer topoStatsConnTimings.Record(statsKey, startTime) bytes, version, err := st.conn.Get(ctx, filePath) if err != nil { @@ -143,6 +145,7 @@ func (st *StatsConn) List(ctx context.Context, filePathPrefix string) ([]KVInfo, } defer st.readSem.Release(1) topoStatsConnReadWaitTimings.Record(statsKey, startTime) + startTime = time.Now() // reset defer topoStatsConnTimings.Record(statsKey, startTime) bytes, err := st.conn.List(ctx, filePathPrefix) if err != nil {