mirror of
https://github.com/TeaOSLab/EdgeNode.git
synced 2025-12-16 07:46:36 +08:00
实现新的计数器算法(将时间分片, 统计更加精准)
This commit is contained in:
12
internal/utils/counters/span.go
Normal file
12
internal/utils/counters/span.go
Normal file
@@ -0,0 +1,12 @@
|
||||
// Copyright 2023 GoEdge CDN goedge.cdn@gmail.com. All rights reserved. Official site: https://goedge.cn .
|
||||
|
||||
package counters
|
||||
|
||||
type Span struct {
|
||||
Timestamp int64
|
||||
Count uint64
|
||||
}
|
||||
|
||||
func NewSpan() *Span {
|
||||
return &Span{}
|
||||
}
|
||||
Reference in New Issue
Block a user