Skip to content

remove unused producer latency metrics#529

Merged
bmckerry merged 1 commit intomainfrom
ben/remove-metrics
Mar 25, 2026
Merged

remove unused producer latency metrics#529
bmckerry merged 1 commit intomainfrom
ben/remove-metrics

Conversation

@bmckerry
Copy link
Copy Markdown
Member

We're only using the p99_* producer latency metrics in our dashboards & alerting.
This removes some of our highest-volume metrics.

@bmckerry bmckerry requested review from a team as code owners March 24, 2026 15:13
Copy link
Copy Markdown

@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.

Fix All in Cursor

Bugbot Autofix prepared a fix for the issue found in the latest run.

  • ✅ Fixed: Test call count not updated after metric removal
    • Updated both affected tests to assert the reduced timing call counts that match the remaining p99-only metrics.

Create PR

Or push these changes by commenting:

@cursor push 1ac364f5d3
Preview (1ac364f5d3)
diff --git a/tests/backends/test_kafka_producer.py b/tests/backends/test_kafka_producer.py
--- a/tests/backends/test_kafka_producer.py
+++ b/tests/backends/test_kafka_producer.py
@@ -24,7 +24,7 @@
 
     producer_stats_callback(stats_json, None)
 
-    assert mock_metrics.timing.call_count == 4
+    assert mock_metrics.timing.call_count == 2
     mock_metrics.timing.assert_any_call(
         "arroyo.producer.librdkafka.p99_int_latency",
         2.0,
@@ -82,7 +82,7 @@
 
     producer_stats_callback(stats_json, None)
 
-    assert mock_metrics.timing.call_count == 6
+    assert mock_metrics.timing.call_count == 3
     mock_metrics.timing.assert_any_call(
         "arroyo.producer.librdkafka.p99_int_latency",
         2.0,

This Bugbot Autofix run was free. To enable autofix for future PRs, go to the Cursor dashboard.

@bmckerry bmckerry force-pushed the ben/remove-metrics branch from 3cf1eba to 53240de Compare March 24, 2026 15:29
@bmckerry bmckerry merged commit f71e6bf into main Mar 25, 2026
18 checks passed
@bmckerry bmckerry deleted the ben/remove-metrics branch March 25, 2026 15:06
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.

3 participants