vikramahuja1001 commented on code in PR #6020:
URL: https://github.com/apache/hive/pull/6020#discussion_r2266517495


##########
standalone-metastore/metastore-client/src/main/java/org/apache/hadoop/hive/metastore/utils/TableFetcher.java:
##########
@@ -117,6 +119,35 @@ public List<TableName> getTables() throws Exception {
     return candidates;
   }
 
+  public List<Table> getTables(int maxBatchSize) throws Exception {
+    List<Table> candidates = new ArrayList<>();

Review Comment:
   `      Database database = client.getDatabase(catalogName, db);`
   `      if (MetaStoreUtils.checkIfDbNeedsToBeSkipped(database)) {`
   `        LOG.debug("Skipping table under database: {}", db);`
   `        continue;`
   `      }`
   `      if (MetaStoreUtils.isDbBeingPlannedFailedOver(database)) {`
   `        LOG.info("Skipping table that belongs to database {} being failed 
over.", db);`
   `        continue;`
   `      }`
   `      List<String> tablesNames = client.listTableNamesByFilter(catalogName, 
db, tableFilter, -1);`
   
   The above part can be moved to a common method and can be used for both 
getTables and getTableNames method. 



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