apache/iceberg · warning · UnsupportedOperationException

%s does not expose configuration properties

Error message

%s does not expose configuration properties

What it means

FileIO.properties() is a default method that returns the configuration map used to initialize the FileIO. Implementations are not required to expose their configuration; the default implementation throws UnsupportedOperationException naming the concrete class. Callers must treat property exposure as optional capability.

Source

Thrown at api/src/main/java/org/apache/iceberg/io/FileIO.java:107

  /** Convenience method to {@link #deleteFile(String) delete} an {@link InputFile}. */
  default void deleteFile(InputFile file) {
    deleteFile(file.location());
  }

  /** Convenience method to {@link #deleteFile(String) delete} an {@link OutputFile}. */
  default void deleteFile(OutputFile file) {
    deleteFile(file.location());
  }

  /**
   * Returns the property map used to configure this FileIO
   *
   * @return the property map used to configure this FileIO
   * @throws UnsupportedOperationException if this FileIO does not expose its configuration
   *     properties
   */
  default Map<String, String> properties() {
    throw new UnsupportedOperationException(
        String.format("%s does not expose configuration properties", this.getClass()));
  }

  /**
   * Initialize File IO from catalog properties.
   *
   * @param properties catalog properties
   */
  default void initialize(Map<String, String> properties) {}

  /**
   * Close File IO to release underlying resources.
   *
   * <p>Calling this method is only required when this FileIO instance is no longer expected to be
   * used, and the resources it holds need to be explicitly released to avoid resource leaks.
   */
  @Override
  default void close() {}

View on GitHub (pinned to 86d9c8fc54)

Solutions

  1. Implement properties() in your FileIO class to return the map passed to initialize(Map<String,String>)
  2. Wrap the call in a try/catch for UnsupportedOperationException and fall back to tracking config at the call site
  3. Pass and retain the configuration separately (you already hold the map you gave to initialize())

Example fix

// before
Map<String, String> conf = io.properties();
// after
Map<String, String> conf;
try {
  conf = io.properties();
} catch (UnsupportedOperationException e) {
  conf = retainedConfigAtConstruction; // config captured when initialize() was called
}
Defensive patterns

Strategy: try-catch

Validate before calling

// capability probe
boolean exposesProps;
try { io.properties(); exposesProps = true; } catch (UnsupportedOperationException e) { exposesProps = false; }

Try / catch

try { conf = io.properties(); } catch (UnsupportedOperationException e) { conf = myRetainedConfig; }

Prevention

When it happens

Trigger: Calling properties() on a FileIO implementation that does not override properties() — e.g. a custom FileIO, HadoopFileIO in some configurations, or any implementation built before the method existed.

Common situations: Debugging/catalog code introspecting a FileIO's config; util code copying configuration between FileIO instances; upgrading Iceberg and calling properties() on custom FileIO classes written against the older interface.

Related errors


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