Kuan Po Tseng created KAFKA-16477:
-------------------------------------
Summary: Detect thread leaked client-metrics-reaper in tests
Key: KAFKA-16477
URL: https://issues.apache.org/jira/browse/KAFKA-16477
Project: Kafka
Issue Type: Improvement
Reporter: Kuan Po Tseng
Assignee: Kuan Po Tseng
After profiling the kafka tests, tons of `client-metrics-reaper` thread not
cleanup after BrokerServer shutdown.
The thread {{client-metrics-reaper}} comes from
[ClientMetricsManager#expirationTimer|https://github.com/apache/kafka/blob/a2ee0855ee5e73f3a74555d52294bb4acfd28945/server/src/main/java/org/apache/kafka/server/ClientMetricsManager.java#L115],
and BrokerServer#shudown doesn't close ClientMetricsManager which let the
timer thread still runs in background.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)