This is an automated email from the ASF dual-hosted git repository.

adoroszlai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ozone.git


The following commit(s) were added to refs/heads/master by this push:
     new b274f1fb1a HDDS-12335. Fix ozone admin namespace summary to give 
complete output (#7908)
b274f1fb1a is described below

commit b274f1fb1ab888e657b8f59bae75d167eac9c5fc
Author: Gargi Jaiswal <[email protected]>
AuthorDate: Wed Feb 19 21:21:55 2025 +0530

    HDDS-12335. Fix ozone admin namespace summary to give complete output 
(#7908)
---
 .../apache/hadoop/ozone/admin/nssummary/SummarySubCommand.java | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git 
a/hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/admin/nssummary/SummarySubCommand.java
 
b/hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/admin/nssummary/SummarySubCommand.java
index 03846f8160..a4905d255c 100644
--- 
a/hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/admin/nssummary/SummarySubCommand.java
+++ 
b/hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/admin/nssummary/SummarySubCommand.java
@@ -78,10 +78,12 @@ public Void call() throws Exception {
       printKVSeparator();
       System.out.println(summaryResponse.get("type"));
 
-      int numVol = summaryResponse.path("numVolume").asInt(-1);
-      int numBucket = summaryResponse.path("numBucket").asInt(-1);
-      int numDir = summaryResponse.path("numDir").asInt(-1);
-      int numKey = summaryResponse.path("numKey").asInt(-1);
+      JsonNode countStatsNode = summaryResponse.path("countStats");
+
+      int numVol = countStatsNode.path("numVolume").asInt(-1);
+      int numBucket = countStatsNode.path("numBucket").asInt(-1);
+      int numDir = countStatsNode.path("numDir").asInt(-1);
+      int numKey = countStatsNode.path("numKey").asInt(-1);
 
       if (numVol != -1) {
         printWithUnderline("Volumes", false);


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to