Add a series ops metric "purge_on_request"

It counts series deletions triggered via the API.
This commit is contained in:
beorn7 2016-01-11 17:22:16 +01:00
parent 49fe948b9a
commit cb117d8346
2 changed files with 2 additions and 0 deletions

View file

@ -57,6 +57,7 @@ const (
unarchive = "unarchive"
memoryPurge = "purge_from_memory"
archivePurge = "purge_from_archive"
requestedPurge = "purge_on_request"
memoryMaintenance = "maintenance_in_memory"
archiveMaintenance = "maintenance_in_archive"

View file

@ -527,6 +527,7 @@ func (s *memorySeriesStorage) DropMetricsForFingerprints(fps ...model.Fingerprin
}
s.fpLocker.Unlock(fp)
s.seriesOps.WithLabelValues(requestedPurge).Inc()
}
}