mjsax commented on code in PR #17781: URL: https://github.com/apache/kafka/pull/17781#discussion_r1838848038
########## clients/src/test/java/org/apache/kafka/clients/consumer/KafkaConsumerTest.java: ########## @@ -3501,6 +3533,17 @@ private boolean requestGenerated(MockClient client, ApiKeys apiKey) { return client.requests().stream().anyMatch(request -> request.requestBuilder().apiKey().equals(apiKey)); } + private Map<MetricName, KafkaMetric> customMetrics() { + MetricConfig metricConfig = new MetricConfig(); + Object lock = new Object(); + MetricName metricNameOne = new MetricName("metricOne", "stream-metrics", "description for metric one", new HashMap<>()); + MetricName metricNameTwo = new MetricName("metricTwo", "stream-metrics", "description for metric two", new HashMap<>()); Review Comment: I cannot remember what we did on the other PRs that we merged already -- I think, if we would create a user metric that is the same as an exiting consumer metric, it would get dropped on the floor. But do we have a test for this case? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org