saihemanth-cloudera commented on code in PR #5882:
URL: https://github.com/apache/hive/pull/5882#discussion_r2159788765


##########
standalone-metastore/metastore-rest-catalog/src/main/java/org/apache/iceberg/rest/HMSCachingCatalog.java:
##########
@@ -24,30 +24,45 @@
 import java.util.Map;
 import java.util.Set;
 import org.apache.iceberg.CachingCatalog;
+import org.apache.iceberg.Schema;
 import org.apache.iceberg.catalog.Catalog;
 import org.apache.iceberg.catalog.Namespace;
 import org.apache.iceberg.catalog.SupportsNamespaces;
 import org.apache.iceberg.catalog.TableIdentifier;
 import org.apache.iceberg.exceptions.NamespaceNotEmptyException;
 import org.apache.iceberg.exceptions.NoSuchNamespaceException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 
 /**
  * Class that wraps an Iceberg Catalog to cache tables.
  * @param <CATALOG> the catalog class
  */
 public class HMSCachingCatalog<CATALOG extends Catalog & SupportsNamespaces> 
extends CachingCatalog implements SupportsNamespaces {
+  private static final Logger LOG = 
LoggerFactory.getLogger(HMSCachingCatalog.class);
   protected final CATALOG nsCatalog;
   
   public HMSCachingCatalog(CATALOG catalog, long expiration) {
-    super(catalog, true, expiration, Ticker.systemTicker());
+    super(catalog, false, expiration, Ticker.systemTicker());
     nsCatalog = catalog;
   }
 
   public CATALOG hmsUnwrap() {
     return nsCatalog;
   }
 
+  public void invalidateTable(String dbName, String tableName) {
+    super.invalidateTable(TableIdentifier.of(dbName, tableName));
+  }
+
+  @Override
+  public void invalidateTable(TableIdentifier tableIdentifier) {
+    if (LOG.isDebugEnabled()) {
+      LOG.debug("Avoid invalidating table: {}", tableIdentifier);
+    }

Review Comment:
   We can then do super.invalidateTable() 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.

To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org
For additional commands, e-mail: gitbox-h...@hive.apache.org

Reply via email to