all repos

onasty @ 184b6cc396589dbfcf9c03e019409683a7cbb1f0

a one-time notes service
1 files changed, 0 insertions(+), 28 deletions(-)
refactor: remove unused code (#66)

Author: Smirnov Oleksandr ss2316544@gmail.com
Committed by: GitHub noreply@github.com
Committed at: 2025-01-15 18:14:53 +0200
Parent: 229e876
D

@@ -1,28 +0,0 @@

-package metrics - -import ( - "github.com/prometheus/client_golang/prometheus" - "github.com/prometheus/client_golang/prometheus/promauto" -) - -var ( - emailSentSuccessfully = promauto.NewCounter(prometheus.CounterOpts{ //nolint:exhaustruct - Name: "mail_sent_total", - Help: "the total number of successfully sent email", - }) - - emailFailedToSend = promauto.NewCounterVec(prometheus.CounterOpts{ //nolint:exhaustruct - Name: "mail_failed_total", - Help: "the total number of email that failed to send", - }, []string{"request_id"}) -) - -func RecordEmailSent() { - go emailSentSuccessfully.Inc() -} - -func RecordEmailFailed(reqid string) { - go emailFailedToSend.With(prometheus.Labels{ - "request_id": reqid, - }).Inc() -}