mirror of
https://github.com/pocket-id/pocket-id.git
synced 2025-12-06 01:10:22 +03:00
[PR #295] [CLOSED] feat: add prometheus metrics #879
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/pocket-id/pocket-id/pull/295
Author: @nikdoof
Created: 3/4/2025
Status: ❌ Closed
Base:
main← Head:prometheus_metrics📝 Commits (1)
9f05d85feat: add prometheus metrics📊 Changes
4 files changed (+137 additions, -0 deletions)
View changed files
📝
backend/go.mod(+8 -0)📝
backend/go.sum(+16 -0)📝
backend/internal/bootstrap/router_bootstrap.go(+5 -0)➕
backend/internal/middleware/metrics.go(+108 -0)📄 Description
Resolves #262
This uses the upstream supported mod of
github.com/prometheus/client_golang/prometheus/promhttp. Additions consists of a middleware and a singular route to handle/metrics.By using the standard
prometheus_clientlibrary we also get a lot of free metrics for the Go internals, the additional middleware records any requests handled by Gin.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.