feat(monitoring): add transfer retry Prometheus metrics
This commit is contained in:
parent
42764110f0
commit
2a9e6084fc
1 changed files with 27 additions and 0 deletions
|
|
@ -210,6 +210,27 @@ var (
|
|||
},
|
||||
[]string{"reason"}, // ClamAV, validation, quota, etc.
|
||||
)
|
||||
|
||||
// v0.701: Transfer Retry Metrics
|
||||
TransferRetryTotal = promauto.NewCounter(prometheus.CounterOpts{
|
||||
Name: "veza_transfer_retry_total",
|
||||
Help: "Total number of transfer retry attempts",
|
||||
})
|
||||
|
||||
TransferRetrySuccess = promauto.NewCounter(prometheus.CounterOpts{
|
||||
Name: "veza_transfer_retry_success_total",
|
||||
Help: "Total number of successful transfer retries",
|
||||
})
|
||||
|
||||
TransferRetryFailures = promauto.NewCounter(prometheus.CounterOpts{
|
||||
Name: "veza_transfer_retry_failures_total",
|
||||
Help: "Total number of failed transfer retries",
|
||||
})
|
||||
|
||||
TransferRetryPermanent = promauto.NewCounter(prometheus.CounterOpts{
|
||||
Name: "veza_transfer_retry_permanent_failures_total",
|
||||
Help: "Total number of permanently failed transfers (max retries exceeded)",
|
||||
})
|
||||
)
|
||||
|
||||
// Middleware pour enregistrer les métriques HTTP
|
||||
|
|
@ -325,3 +346,9 @@ func RecordPlaylistCreated() {
|
|||
func RecordUploadFailed(reason string) {
|
||||
UploadsFailedTotal.WithLabelValues(reason).Inc()
|
||||
}
|
||||
|
||||
// v0.701: Transfer Retry Metrics
|
||||
func RecordTransferRetry() { TransferRetryTotal.Inc() }
|
||||
func RecordTransferRetrySuccess() { TransferRetrySuccess.Inc() }
|
||||
func RecordTransferRetryFailure() { TransferRetryFailures.Inc() }
|
||||
func RecordTransferRetryPermanent() { TransferRetryPermanent.Inc() }
|
||||
|
|
|
|||
Loading…
Reference in a new issue