nastra commented on code in PR #2043:
URL: https://github.com/apache/fluss/pull/2043#discussion_r2610148541
##########
fluss-lake/fluss-lake-iceberg/src/main/java/org/apache/fluss/lake/iceberg/IcebergLakeCatalog.java:
##########
@@ -119,8 +131,35 @@ public void createTable(TablePath tablePath,
TableDescriptor tableDescriptor, Co
@Override
public void alterTable(TablePath tablePath, List<TableChange>
tableChanges, Context context)
throws TableNotExistException {
- throw new UnsupportedOperationException(
- "Alter table is not supported for Iceberg at the moment");
+ try {
+ Table table =
icebergCatalog.loadTable(toIcebergTableIdentifier(tablePath));
+ UpdateProperties updateProperties = table.updateProperties();
+ for (TableChange tableChange : tableChanges) {
+ if (tableChange instanceof TableChange.SetOption) {
+ TableChange.SetOption option = (TableChange.SetOption)
tableChange;
+ checkArgument(
Review Comment:
@MehulBatra does it make sense to throw IAE exception here, since the
alterTable API doesn't specify what to throw in such a case.
--
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]