smengcl commented on a change in pull request #1164: HDDS-1829 On OM reload/restart OmMetrics#numKeys should be updated URL: https://github.com/apache/hadoop/pull/1164#discussion_r307531341
########## File path: hadoop-hdds/common/src/main/java/org/apache/hadoop/utils/db/TypedTable.java ########## @@ -205,6 +205,16 @@ public String getName() throws IOException { return rawTable.getName(); } + @Override + public long getEstimatedKeyCount() throws IOException { + if (rawTable instanceof RDBTable) { + return rawTable.getEstimatedKeyCount(); + } + throw new IllegalArgumentException( + "Unsupported operation getEstimatedKeyCount() on table type " + + rawTable.getClass().getCanonicalName()); Review comment: Does IllegalArgumentException look good here? ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: common-issues-h...@hadoop.apache.org