blob: 3aa91a476b231154cc8b597fd4a6b49c9a39dc4b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
package telemetry
import "sync/atomic"
var logicalChecksCountTotal atomic.Uint64
// RecordLogicalChecks records the number of logical checks performed by the server.
func RecordLogicalChecks(logicalCheckCount uint64) {
logicalChecksCountTotal.Add(logicalCheckCount)
}
// loadLogicalChecksCount returns the total number of logical checks performed by the server,
// zeroing out the existing count as well.
func loadLogicalChecksCount() uint64 {
return logicalChecksCountTotal.Swap(0)
}
|