Skip to content

apollo_network_benchmark: added network event metrics#11547

Open
sirandreww-starkware wants to merge 1 commit into01-07-apollo_network_benchmark_added_sqmr_session_metricsfrom
01-07-apollo_network_benchmark_added_network_event_metrics
Open

apollo_network_benchmark: added network event metrics#11547
sirandreww-starkware wants to merge 1 commit into01-07-apollo_network_benchmark_added_sqmr_session_metricsfrom
01-07-apollo_network_benchmark_added_network_event_metrics

Conversation

@sirandreww-starkware
Copy link
Contributor

@sirandreww-starkware sirandreww-starkware commented Jan 8, 2026

Note

Low Risk
Low risk: adds a new labeled counter metric and plumbs it into the existing NetworkMetrics struct without changing networking behavior or data handling.

Overview
Adds a new labeled counter, NETWORK_EVENT_COUNTER (network_event_counter), to the broadcast network stress test node metrics, using EVENT_TYPE_LABELS.

Updates create_network_metrics to construct EventMetrics and pass it via NetworkMetrics.event_metrics (previously None), enabling event-type network telemetry during the benchmark.

Written by Cursor Bugbot for commit 21df92c. This will update automatically on new commits. Configure here.

@reviewable-StarkWare
Copy link

This change is Reviewable

Copy link
Contributor Author

sirandreww-starkware commented Jan 8, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@sirandreww-starkware sirandreww-starkware marked this pull request as ready for review January 8, 2026 17:42
@sirandreww-starkware sirandreww-starkware self-assigned this Jan 8, 2026
@github-actions
Copy link

github-actions bot commented Feb 8, 2026

There hasn't been any activity on this pull request recently, and in order to prioritize active work, it has been marked as stale.
This PR will be closed and locked in 7 days if no further activity occurs.
Thank you for your contributions!

@github-actions github-actions bot added the stale label Feb 8, 2026
@github-actions github-actions bot closed this Feb 16, 2026
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

MetricCounter { NETWORK_STRESS_TEST_RECEIVED_MESSAGES, "network_stress_test_received_messages", "Number of stress test messages received via broadcast", init = 0 },
LabeledMetricCounter { NETWORK_DROPPED_BROADCAST_MESSAGES, "network_dropped_broadcast_messages", "Number of dropped broadcast messages by reason", init = 0, labels = NETWORK_BROADCAST_DROP_LABELS },
LabeledMetricCounter { NETWORK_EVENT_COUNTER, "network_event_counter", "Network events counter by type", init = 0, labels = EVENT_TYPE_LABELS },

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New event counter metric never gets registered

Medium Severity

The new NETWORK_EVENT_COUNTER metric is never registered. During NetworkManager::new(), the event_metrics field is take()n from NetworkMetrics and moved into MixedBehaviour, so when NetworkMetrics::register() runs later in run(), event_metrics is already None and the counter isn't registered. The register_metrics() function also doesn't include NETWORK_EVENT_COUNTER.register(). Other components like apollo_consensus_manager handle this by explicitly registering their event counter in their register_metrics().

Additional Locations (1)

Fix in Cursor Fix in Web

@sirandreww-starkware sirandreww-starkware force-pushed the 01-07-apollo_network_benchmark_added_sqmr_session_metrics branch from 9f1fb1f to ce5b018 Compare February 19, 2026 08:04
@sirandreww-starkware sirandreww-starkware force-pushed the 01-07-apollo_network_benchmark_added_network_event_metrics branch from f6b5f12 to 0789a94 Compare February 19, 2026 08:04
@sirandreww-starkware sirandreww-starkware force-pushed the 01-07-apollo_network_benchmark_added_sqmr_session_metrics branch from ce5b018 to 74f56ff Compare March 16, 2026 15:13
@sirandreww-starkware sirandreww-starkware force-pushed the 01-07-apollo_network_benchmark_added_network_event_metrics branch from 0789a94 to 21df92c Compare March 16, 2026 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants