Copilot commented on code in PR #18708:
URL: https://github.com/apache/iotdb/pull/18708#discussion_r4085398718
##########
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/concurrent/ThreadName.java:
##########
@@ -394,10 +393,8 @@ public enum ThreadName {
SYSTEM_SCHEDULE_METRICS,
RESOURCE_CONTROL_DISK_STATISTIC,
PROMETHEUS_REPORTER_SNAPSHOT_UPDATER,
- PROMETHEUS_REACTOR_HTTP_EPOLL,
- PROMETHEUS_REACTOR_HTTP_NIO,
- PROMETHEUS_REACTOR_HTTP_EPOLL,
- PROMETHEUS_BOUNDED_ELASTIC));
+ PROMETHEUS_REPORTER_HTTP,
+ PROMETHEUS_HTTP_DISPATCHER));
Review Comment:
These new threads are not actually attributed to the metrics module.
`threadNameSetList` includes `iotConsensusV2ThreadNames` before
`ratisThreadNames` (lines 413–427), but the parallel `modules` array has no
corresponding second `IOT_CONSENSUS` entry (lines 439–461), so
`metricsThreadNames` is paired with `ThreadModule.RPC`. Consequently both
Prometheus threads are reported as RPC by `getModuleTheThreadBelongs`, contrary
to the intended classification. Add the missing module entry (and preferably a
mapping test) so the arrays remain aligned.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]