devmadhuu commented on code in PR #6987:
URL: https://github.com/apache/ozone/pull/6987#discussion_r1694660940


##########
hadoop-ozone/recon/src/main/java/org/apache/hadoop/ozone/recon/spi/impl/OzoneManagerServiceProviderImpl.java:
##########
@@ -539,7 +554,7 @@ boolean innerGetAndApplyDeltaUpdatesFromOM(long 
fromSequenceNumber,
    * full snapshot from Ozone Manager.
    */
   @VisibleForTesting
-  public boolean syncDataFromOM() {
+  public boolean syncDataFromOM() throws IOException {

Review Comment:
   Yes , sure.. thanks for pointing out.



##########
hadoop-ozone/recon/src/main/java/org/apache/hadoop/ozone/recon/spi/impl/OzoneManagerServiceProviderImpl.java:
##########
@@ -623,6 +639,34 @@ public boolean syncDataFromOM() {
     return true;
   }
 
+  private void printFileAndKeyTableCount() throws IOException {
+    Table fileTable = omMetadataManager.getTable("fileTable");
+    Table keyTable = omMetadataManager.getTable("keyTable");
+    if (keyTable == null) {
+      LOG.error("Table keyTable not found in OM Metadata.");
+    }
+
+    if (LOG.isDebugEnabled() && null != keyTable) {
+      try (TableIterator<String, ? extends Table.KeyValue<String, ?>> iterator
+               = keyTable.iterator()) {
+        long count = Iterators.size(iterator);
+        LOG.debug("keyTable Table count: {}", count);

Review Comment:
   Ok sure. will make it generic.



-- 
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]

Reply via email to