Add new metrics

This commit is contained in:
9seconds
2019-12-03 10:02:56 +03:00
parent 7788b169b6
commit 87de28636a
6 changed files with 61 additions and 5 deletions
+8
View File
@@ -137,6 +137,14 @@ func (s *statsStatsd) ReplayDetected() {
s.gauge("replay_attacks", 1)
}
func (s *statsStatsd) AuthenticationFailed() {
s.gauge("authentication_failed", 1)
}
func (s *statsStatsd) CloakedRequest() {
s.gauge("cloaked_requests", 1)
}
func (s *statsStatsd) gauge(metric string, value int64, tags ...*statsStatsdTag) {
key, tagList := s.prepareVals(metric, tags)
s.initGauge(metric, key, tagList)