devmadhuu commented on code in PR #6400:
URL: https://github.com/apache/ozone/pull/6400#discussion_r1535050219
##########
hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/admin/nssummary/NSSummaryCLIUtils.java:
##########
@@ -107,8 +108,9 @@ public static String makeHttpCall(StringBuffer url, String
path,
}
}
- public static HashMap<String, Object> getResponseMap(String response) {
- return new Gson().fromJson(response, HashMap.class);
+ public static HashMap<String, Object> getResponseMap(String response)
Review Comment:
I don't think so, we need this wrapper method. Call JsonUtils method
directly where needed.
##########
hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/admin/nssummary/DiskUsageSubCommand.java:
##########
@@ -101,21 +99,20 @@ public Void call() throws Exception {
return null;
}
- HashMap<String, Object> duResponse = getResponseMap(response);
+ JsonNode duResponse = JsonUtils.readTree(response);
Review Comment:
Curious to know the reason why we changed this from HashMap to JsonNode
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]