jerryshao commented on code in PR #6396:
URL: https://github.com/apache/gravitino/pull/6396#discussion_r1944430131


##########
iceberg/iceberg-common/src/main/java/org/apache/gravitino/iceberg/common/ops/IcebergCatalogWrapper.java:
##########
@@ -228,10 +234,18 @@ public void renameView(RenameTableRequest request) {
   }
 
   public boolean viewExists(TableIdentifier viewIdentifier) {
+    if (!(catalog instanceof ViewCatalog)) {
+      return false;

Review Comment:
   Though I don't know the behavior of Trino, from my feeling, it is better to 
throw an unsupported exception to let user clearly know the problem, rather 
than return `false`.
   
   `false` can have different meaning, like `ViewCatalog` is supported but this 
view is not existed. If we blindly return `false`, how do we differentiate 
whether it is not supported or not existed?



-- 
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: commits-unsubscr...@gravitino.apache.org

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

Reply via email to