From 3bb20562793b6ac4797d31fb496155eef6843b9e Mon Sep 17 00:00:00 2001 From: lhy1024 Date: Tue, 28 Dec 2021 16:00:06 +0800 Subject: [PATCH] address comment Signed-off-by: lhy1024 --- server/statistics/hot_peer_cache_test.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/server/statistics/hot_peer_cache_test.go b/server/statistics/hot_peer_cache_test.go index bf439700efb5..4997bbae77fe 100644 --- a/server/statistics/hot_peer_cache_test.go +++ b/server/statistics/hot_peer_cache_test.go @@ -178,7 +178,7 @@ func checkOp(c *C, ret []*HotPeerStat, storeID uint64, actionType ActionType) { } // checkIntervalSum checks whether the interval sum of the peers are different. -func checkIntervalSum(cache *hotPeerCache, region *core.RegionInfo, peerCount int) bool { +func checkIntervalSum(cache *hotPeerCache, region *core.RegionInfo) bool { var intervalSums []int for _, peer := range region.GetPeers() { oldItem := cache.getOldHotPeerStat(region.GetID(), peer.StoreId) @@ -200,9 +200,6 @@ func checkIntervalSumContinuous(c *C, intervalSums map[uint64]int, rets []*HotPe new := int(ret.getIntervalSum() / 1000000000) if ret.source == direct { if old, ok := intervalSums[ret.StoreID]; ok { - if new != (old+int(interval))%RegionHeartBeatReportInterval { - println(ret.StoreID, old, new, interval) - } c.Assert(new, Equals, (old+int(interval))%RegionHeartBeatReportInterval) } }