From 1efca9c28d87f5755996d8d3039c5ad5e7483b10 Mon Sep 17 00:00:00 2001 From: Nishant Das Date: Mon, 6 Jan 2025 18:13:22 +0800 Subject: [PATCH] Add Ability to Trace IDONTWANT Control Messages (#14778) * Trace IDONTWANT Requests * Changelog --- CHANGELOG.md | 1 + beacon-chain/p2p/pubsub_tracer.go | 1 + 2 files changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 169720080b..ac63d5716a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,7 @@ The format is based on Keep a Changelog, and this project adheres to Semantic Ve - Add field param placeholder for Electra blob target and max to pass spec tests. - Add EIP-7691: Blob throughput increase. - SSZ files generation: Remove the `// Hash: ...` header. +- Trace IDONTWANT Messages in Pubsub. ### Changed diff --git a/beacon-chain/p2p/pubsub_tracer.go b/beacon-chain/p2p/pubsub_tracer.go index 84ed1b1240..898ba6d13c 100644 --- a/beacon-chain/p2p/pubsub_tracer.go +++ b/beacon-chain/p2p/pubsub_tracer.go @@ -108,6 +108,7 @@ func (g gossipTracer) setMetricFromRPC(act action, subCtr prometheus.Counter, pu ctrlCtr.WithLabelValues("prune").Add(float64(len(rpc.Control.Prune))) ctrlCtr.WithLabelValues("ihave").Add(float64(len(rpc.Control.Ihave))) ctrlCtr.WithLabelValues("iwant").Add(float64(len(rpc.Control.Iwant))) + ctrlCtr.WithLabelValues("idontwant").Add(float64(len(rpc.Control.Idontwant))) } for _, msg := range rpc.Publish { // For incoming messages from pubsub, we do not record metrics for them as these values