Closed
Description
Feature Request / Improvement
ExpireSnapshots is NOP when there is no snapshot. But I think it's more intuitive to clean expired metadata in that case, if we're told to do so. For example, I would expect this test to pass
@TestTemplate
public void test() throws Exception {
table.updateSchema().addColumn("extra_col1", Types.StringType.get()).commit();
table.updateSchema().addColumn("extra_col2", Types.StringType.get()).commit();
removeSnapshots(table)
.expireOlderThan(System.currentTimeMillis())
.cleanExpiredMetadata(true)
.commit();
assertThat(table.schemas()).hasSize(1);
}
Query engine
None
Willingness to contribute
- I can contribute this improvement/feature independently
- I would be willing to contribute this improvement/feature with guidance from the Iceberg community
- I cannot contribute this improvement/feature at this time