aboutsummaryrefslogtreecommitdiff
path: root/federationapi/federationapi.go
diff options
context:
space:
mode:
authorTill <2353100+S7evinK@users.noreply.github.com>2022-12-05 13:53:36 +0100
committerGitHub <noreply@github.com>2022-12-05 13:53:36 +0100
commite245a26f6bcb4d134015f49f621b6d639a78707f (patch)
tree87bd54e9d6ad35a225fe8f6dd9bb102c161e5f2e /federationapi/federationapi.go
parentb65f89e61e95b295e46ac3ade3c860b56126fa90 (diff)
Enable/Disable internal metrics (#2899)
Basically enables us to use `test.WithAllDatabases` when testing internal HTTP APIs, as this would otherwise result in Prometheus complaining about already registered metric names.
Diffstat (limited to 'federationapi/federationapi.go')
-rw-r--r--federationapi/federationapi.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/federationapi/federationapi.go b/federationapi/federationapi.go
index 85425122..87eb751f 100644
--- a/federationapi/federationapi.go
+++ b/federationapi/federationapi.go
@@ -43,8 +43,8 @@ import (
// AddInternalRoutes registers HTTP handlers for the internal API. Invokes functions
// on the given input API.
-func AddInternalRoutes(router *mux.Router, intAPI api.FederationInternalAPI) {
- inthttp.AddRoutes(intAPI, router)
+func AddInternalRoutes(router *mux.Router, intAPI api.FederationInternalAPI, enableMetrics bool) {
+ inthttp.AddRoutes(intAPI, router, enableMetrics)
}
// AddPublicRoutes sets up and registers HTTP handlers on the base API muxes for the FederationAPI component.