This is an automated email from the ASF dual-hosted git repository. chia7712 pushed a commit to branch trunk in repository https://gitbox.apache.org/repos/asf/kafka.git
The following commit(s) were added to refs/heads/trunk by this push: new a5e3bfa2329 KAFKA-19527 improve the docs of LogDirDescription for remote storage (#20211) a5e3bfa2329 is described below commit a5e3bfa2329b29be83c64ea29eb1c4eb20572acd Author: Hong-Yi Chen <apala...@gmail.com> AuthorDate: Wed Jul 30 20:41:45 2025 +0800 KAFKA-19527 improve the docs of LogDirDescription for remote storage (#20211) Clarifies that the fields `LogDirDescription#totalBytes`, `LogDirDescription#usableBytes`, and `ReplicaInfo#size` do not include the size of remote storage by updating their corresponding docs. Reviewers: Chia-Ping Tsai <chia7...@gmail.com> --- .../main/java/org/apache/kafka/clients/admin/LogDirDescription.java | 2 ++ .../src/main/java/org/apache/kafka/clients/admin/ReplicaInfo.java | 1 + .../src/main/resources/common/message/DescribeLogDirsResponse.json | 6 +++--- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/clients/src/main/java/org/apache/kafka/clients/admin/LogDirDescription.java b/clients/src/main/java/org/apache/kafka/clients/admin/LogDirDescription.java index 665c86649ba..340e88db160 100644 --- a/clients/src/main/java/org/apache/kafka/clients/admin/LogDirDescription.java +++ b/clients/src/main/java/org/apache/kafka/clients/admin/LogDirDescription.java @@ -67,6 +67,7 @@ public class LogDirDescription { /** * The total size of the volume this log directory is on or empty if the broker did not return a value. * For volumes larger than Long.MAX_VALUE, Long.MAX_VALUE is returned. + * This value does not include the size of data stored in remote storage. */ public OptionalLong totalBytes() { return totalBytes; @@ -75,6 +76,7 @@ public class LogDirDescription { /** * The usable size on the volume this log directory is on or empty if the broker did not return a value. * For usable sizes larger than Long.MAX_VALUE, Long.MAX_VALUE is returned. + * This value does not include the size of data stored in remote storage. */ public OptionalLong usableBytes() { return usableBytes; diff --git a/clients/src/main/java/org/apache/kafka/clients/admin/ReplicaInfo.java b/clients/src/main/java/org/apache/kafka/clients/admin/ReplicaInfo.java index b77375d5960..efe645b704d 100644 --- a/clients/src/main/java/org/apache/kafka/clients/admin/ReplicaInfo.java +++ b/clients/src/main/java/org/apache/kafka/clients/admin/ReplicaInfo.java @@ -33,6 +33,7 @@ public class ReplicaInfo { /** * The total size of the log segments in this replica in bytes. + * This value does not include the size of data stored in remote storage. */ public long size() { return size; diff --git a/clients/src/main/resources/common/message/DescribeLogDirsResponse.json b/clients/src/main/resources/common/message/DescribeLogDirsResponse.json index d05785fe8d8..725d1ad337b 100644 --- a/clients/src/main/resources/common/message/DescribeLogDirsResponse.json +++ b/clients/src/main/resources/common/message/DescribeLogDirsResponse.json @@ -51,11 +51,11 @@ "about": "True if this log is created by AlterReplicaLogDirsRequest and will replace the current log of the replica in the future." }]} ]}, { "name": "TotalBytes", "type": "int64", "versions": "4+", "ignorable": true, "default": "-1", - "about": "The total size in bytes of the volume the log directory is in." + "about": "The total size in bytes of the volume the log directory is in. This value does not include the size of data stored in remote storage." }, { "name": "UsableBytes", "type": "int64", "versions": "4+", "ignorable": true, "default": "-1", - "about": "The usable size in bytes of the volume the log directory is in." + "about": "The usable size in bytes of the volume the log directory is in. This value does not include the size of data stored in remote storage." } ]} ] -} +} \ No newline at end of file