From 9d19996dbd3efd0aaef98a6ab32985221f7bf7cc Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Tue, 8 Jul 2025 21:02:57 +0200 Subject: [PATCH] feat(httpnet): gather metrics for allowlist this wires up https://github.com/ipfs/boxo/pull/971 to make sure explicitly allowlisted hosts have their own metric label if we ever need more flexibility here, this can be exposed as a separate config --- core/node/bitswap.go | 1 + 1 file changed, 1 insertion(+) diff --git a/core/node/bitswap.go b/core/node/bitswap.go index 7e87f8288..976d82765 100644 --- a/core/node/bitswap.go +++ b/core/node/bitswap.go @@ -111,6 +111,7 @@ func Bitswap(serverEnabled, libp2pEnabled, httpEnabled bool) interface{} { httpnet.WithInsecureSkipVerify(httpCfg.TLSInsecureSkipVerify.WithDefault(config.DefaultHTTPRetrievalTLSInsecureSkipVerify)), httpnet.WithMaxBlockSize(int64(maxBlockSize)), httpnet.WithUserAgent(version.GetUserAgentVersion()), + httpnet.WithMetricsLabelsForEndpoints(httpCfg.Allowlist), ) bitswapNetworks = network.New(in.Host.Peerstore(), bitswapLibp2p, bitswapHTTP) } else if libp2pEnabled {