You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "chia7712 (via GitHub)" <gi...@apache.org> on 2025/09/12 04:13:54 UTC

Re: [PR] KAFKA-17876/ KAFKA-19150 Rename AssignmentsManager and RemoteStorageThreadPool metrics [kafka]

chia7712 commented on code in PR #20265:
URL: https://github.com/apache/kafka/pull/20265#discussion_r2342897827


##########
server/src/main/java/org/apache/kafka/server/AssignmentsManager.java:
##########
@@ -74,6 +74,10 @@ public final class AssignmentsManager {
     /**
      * The metric reflecting the number of pending assignments.
      */
+    @Deprecated(since = "4.2")
+    static final MetricName DEPRECATED_QUEUED_REPLICA_TO_DIR_ASSIGNMENTS_METRIC =
+            deprecatedMetricName("QueuedReplicaToDirAssignments");
+
     static final MetricName QUEUED_REPLICA_TO_DIR_ASSIGNMENTS_METRIC =
             metricName("QueuedReplicaToDirAssignments");

Review Comment:
   ditto



##########
storage/src/main/java/org/apache/kafka/storage/internals/log/RemoteStorageThreadPool.java:
##########
@@ -32,7 +32,8 @@
 
 public final class RemoteStorageThreadPool extends ThreadPoolExecutor {
     private static final Logger LOGGER = LoggerFactory.getLogger(RemoteStorageThreadPool.class);
-    private final KafkaMetricsGroup metricsGroup = new KafkaMetricsGroup(this.getClass());
+    private final KafkaMetricsGroup internalsLogMetricsGroup = new KafkaMetricsGroup(this.getClass());

Review Comment:
   Please add comments to remind developers this `internalsLogMetricsGroup` will be removed in 5.0



##########
server/src/main/java/org/apache/kafka/server/AssignmentsManager.java:
##########
@@ -74,6 +74,10 @@ public final class AssignmentsManager {
     /**
      * The metric reflecting the number of pending assignments.
      */
+    @Deprecated(since = "4.2")
+    static final MetricName DEPRECATED_QUEUED_REPLICA_TO_DIR_ASSIGNMENTS_METRIC =

Review Comment:
   Could you please inline `deprecatedMetricName` to streamline code?



-- 
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-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org