go-gitea / gitea

Git with a cup of tea! Painless self-hosted all-in-one software development service, including Git hosting, code review, team collaboration, package registry and CI/CD
https://gitea.com
MIT License
44.19k stars 5.42k forks source link

Add additional Prometheus metrics #17653

Open laurivosandi opened 2 years ago

laurivosandi commented 2 years ago

Feature Description

It's great that people are aware of Prometheus, but what is the usefulness of metrics added in #678 ? Realistically these can't be used for alerting.

How about we add some actually useful metrics:

These were just few to mention. Some of these can be handled by haproxy that sits in front of Gitea which is the case for us of course...

Screenshots

No response

laurivosandi commented 1 year ago

If I am reading right Gitea uses Chi framework so enabling some of those metrics is trivial simply by adding, just make sure no high entropy labels are included: https://pkg.go.dev/github.com/m8as/go-chi-metrics