使用KV存储实现指标统计

This commit is contained in:
刘祥超
2024-04-02 19:54:04 +08:00
parent 750aafdea1
commit e5c5234be8
21 changed files with 1561 additions and 612 deletions

View File

@@ -26,3 +26,7 @@ func (this *tracker) End() {
func (this *tracker) Begin(subLabel string) *tracker {
return Begin(this.label + ":" + subLabel)
}
func (this *tracker) Add(duration time.Duration) {
this.startTime = this.startTime.Add(-duration)
}