Zouxxyy commented on code in PR #4863:
URL: https://github.com/apache/paimon/pull/4863#discussion_r1906826650
##########
paimon-core/src/main/java/org/apache/paimon/catalog/AbstractCatalog.java:
##########
@@ -272,10 +272,14 @@ public void dropTable(Identifier identifier, boolean
ignoreIfNotExists)
try {
getTable(identifier);
} catch (TableNotExistException e) {
+ if (!tableExistsInFileSystem(getTableLocation(identifier),
DEFAULT_MAIN_BRANCH)) {
Review Comment:
As far as I know, before Spark calls `catalog.dropTable`, it actually
invokes `catalog.getTable`. It has already been skipped there.
##########
paimon-spark/paimon-spark-ut/src/test/scala/org/apache/paimon/spark/sql/DDLWithHiveCatalogTestBase.scala:
##########
@@ -621,6 +621,29 @@ abstract class DDLWithHiveCatalogTestBase extends
PaimonHiveTestBase {
}
}
+ test("Paimon DDL with hive catalog: drop table which location has been
deleted") {
Review Comment:
For this case, we need to test both enable and disable the catalog cache
--
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]