apache/iceberg · error · UnsupportedOperationException

The given table change is not a property change:

Error message

The given table change is not a property change: 

What it means

FlinkAlterTableUtil.applyPropertyChanges only accepts TableChange.SetOption and TableChange.ResetOption. Any other change reaching this method is not a table-property change and throws UnsupportedOperationException. It is an internal routing guard so non-property changes are never misapplied as properties.

Solutions

  1. Filter the change list to only TableChange.SetOption/ResetOption before calling applyPropertyChanges.
  2. Route schema changes through applySchemaChanges instead.
  3. Inspect the change object type before dispatch.

Example fix

// before
FlinkAlterTableUtil.applyPropertyChanges(update, allChanges);
// after
FlinkAlterTableUtil.applyPropertyChanges(update, allChanges.stream()
    .filter(c -> c instanceof TableChange.SetOption || c instanceof TableChange.ResetOption)
    .collect(Collectors.toList()));
Defensive patterns

Strategy: validation

Validate before calling

// java
boolean allPropertyChanges = changes.stream().allMatch(c ->
    c instanceof TableChange.SetOption || c instanceof TableChange.ResetOption);
if (!allPropertyChanges) { throw new IllegalArgumentException("non-property change in property path"); }

Type guard

boolean isPropertyChange(TableChange c) {
  return c instanceof TableChange.SetOption || c instanceof TableChange.ResetOption;
}

Try / catch

try {
  FlinkAlterTableUtil.applyPropertyChanges(update, changes);
} catch (UnsupportedOperationException e) {
  if (e.getMessage().startsWith("The given table change is not a property change")) {
    // dispatch to schema-change path instead
  } else { throw e; }
}

Prevention

When it happens

Trigger: Passing a schema or column change into the property-application path, typically a misrouting bug or a caller that collected mixed changes and fed all of them to applyPropertyChanges.

Common situations: Custom catalog code reusing the utility with heterogeneous TableChange lists; a refactor that split applySchemaChanges/applyPropertyChanges incorrectly.

Understand the failure class

Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.

Related errors


AI-assisted analysis of apache/iceberg@86d9c8fc54 (2026-09-12). Data as JSON: /api/errors/f3af7f4b0f778469. Report an issue: GitHub.

Appendix: source

Thrown at flink/v2.3/flink/src/main/java/org/apache/iceberg/flink/util/FlinkAlterTableUtil.java:195

  }

  /**
   * Applies a list of Flink table property changes to an {@link UpdateProperties} operation.
   *
   * @param pendingUpdate an uncommitted UpdateProperty operation to configure
   * @param propertyChanges a list of Flink table changes
   */
  public static void applyPropertyChanges(
      UpdateProperties pendingUpdate, List<TableChange> propertyChanges) {
    for (TableChange change : propertyChanges) {
      if (change instanceof TableChange.SetOption) {
        TableChange.SetOption setOption = (TableChange.SetOption) change;
        pendingUpdate.set(setOption.getKey(), setOption.getValue());
      } else if (change instanceof TableChange.ResetOption) {
        TableChange.ResetOption resetOption = (TableChange.ResetOption) change;
        pendingUpdate.remove(resetOption.getKey());
      } else {
        throw new UnsupportedOperationException(
            "The given table change is not a property change: " + change);
      }
    }
  }

  private static void applyModifyColumn(
      UpdateSchema pendingUpdate, TableChange.ModifyColumn modifyColumn) {
    if (modifyColumn instanceof TableChange.ModifyColumnName) {
      TableChange.ModifyColumnName modifyName = (TableChange.ModifyColumnName) modifyColumn;
      pendingUpdate.renameColumn(modifyName.getOldColumnName(), modifyName.getNewColumnName());
    } else if (modifyColumn instanceof TableChange.ModifyColumnPosition) {
      TableChange.ModifyColumnPosition modifyPosition =
          (TableChange.ModifyColumnPosition) modifyColumn;
      applyModifyColumnPosition(pendingUpdate, modifyPosition);
    } else if (modifyColumn instanceof TableChange.ModifyPhysicalColumnType) {
      TableChange.ModifyPhysicalColumnType modifyType =
          (TableChange.ModifyPhysicalColumnType) modifyColumn;
      Type type = FlinkSchemaUtil.convert(modifyType.getNewType().getLogicalType());

View on GitHub (pinned to 86d9c8fc54)