From 0820519da7adb0aa6308ed5a1f89862cc9e4a497 Mon Sep 17 00:00:00 2001 From: yibin Date: Wed, 14 Aug 2024 14:30:31 +0800 Subject: [PATCH] Add GetTimeDetail for SnapshotRuntimeStats (#1422) Signed-off-by: yibin --- txnkv/txnsnapshot/snapshot.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/txnkv/txnsnapshot/snapshot.go b/txnkv/txnsnapshot/snapshot.go index 58c3a755f..6d2580043 100644 --- a/txnkv/txnsnapshot/snapshot.go +++ b/txnkv/txnsnapshot/snapshot.go @@ -1216,6 +1216,11 @@ func (rs *SnapshotRuntimeStats) String() string { return buf.String() } +// GetTimeDetail returns the timeDetail +func (rs *SnapshotRuntimeStats) GetTimeDetail() *util.TimeDetail { + return rs.timeDetail +} + // GetCmdRPCCount returns the count of the corresponding kind of rpc requests func (rs *SnapshotRuntimeStats) GetCmdRPCCount(cmd tikvrpc.CmdType) int64 { if rs.rpcStats == nil || len(rs.rpcStats.RPCStats) == 0 {