difin commented on code in PR #6690:
URL: https://github.com/apache/hive/pull/6690#discussion_r3784463276


##########
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java:
##########
@@ -2209,6 +2209,20 @@ Boolean hasAppendsOnly(Iterable<Snapshot> snapshots, 
SnapshotContext since) {
     return null;
   }
 
+  @Override
+  public void 
validateCompactionPartition(org.apache.hadoop.hive.ql.metadata.Table hmsTable, 
String partitionName)
+      throws HiveException {
+    Table table = IcebergTableUtil.getTable(conf, hmsTable.getTTable());
+    if (!IcebergTableUtil.hasUndergonePartitionEvolution(table)) {
+      return;
+    }
+    try {
+      IcebergTableUtil.getPartitionSpec(table, partitionName);
+    } catch (MetaException e) {
+      throw new HiveException(e);
+    }
+  }

Review Comment:
   This suggestion doesn't make sense because the method 
`IcebergTableUtil.getPartitionSpec` is a generic util that can be used not only 
in Iceberg compaction.



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