electrum commented on a change in pull request #240: Add HiveCatalog 
implementation
URL: https://github.com/apache/incubator-iceberg/pull/240#discussion_r298690327
 
 

 ##########
 File path: hive/src/main/java/org/apache/iceberg/hive/HiveTableOperations.java
 ##########
 @@ -134,10 +136,11 @@ public void commit(TableMetadata base, TableMetadata 
metadata) {
                 Integer.MAX_VALUE,
                 storageDescriptor(metadata),
                 Collections.emptyList(),
-                new HashMap<>(),
+                Maps.newHashMap(),
                 null,
                 null,
-                ICEBERG_TABLE_TYPE_VALUE);
+            TableType.EXTERNAL_TABLE.toString());
+        tbl.getParameters().put("EXTERNAL", "TRUE"); // using the external 
table type also requires this
 
 Review comment:
   This means the metastore won't delete the location directory when the table 
is dropped. In general, this seems like the right behavior, since Iceberg data 
can be anywhere. But for users that are only going through this interface, how 
is data cleaned up? Because tables are created in the default Hive location 
based on the name, what happens if we do a drop followed by a create (since the 
old data still exists)?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to