say how many leases there are when threshold exceeded (#10567)
This commit is contained in:
parent
28c4b33e7a
commit
cdf933adf1
|
@ -1990,7 +1990,7 @@ func (m *ExpirationManager) emitMetrics() {
|
||||||
// Check if lease count is greater than the threshold
|
// Check if lease count is greater than the threshold
|
||||||
if num > maxLeaseThreshold {
|
if num > maxLeaseThreshold {
|
||||||
if atomic.LoadUint32(m.leaseCheckCounter) > 59 {
|
if atomic.LoadUint32(m.leaseCheckCounter) > 59 {
|
||||||
m.logger.Warn("lease count exceeds warning lease threshold")
|
m.logger.Warn("lease count exceeds warning lease threshold", "have", num, "threshold", maxLeaseThreshold)
|
||||||
atomic.StoreUint32(m.leaseCheckCounter, 0)
|
atomic.StoreUint32(m.leaseCheckCounter, 0)
|
||||||
} else {
|
} else {
|
||||||
atomic.AddUint32(m.leaseCheckCounter, 1)
|
atomic.AddUint32(m.leaseCheckCounter, 1)
|
||||||
|
|
Loading…
Reference in New Issue