apache/iceberg · error · UnsupportedOperationException
The method start(Catalog, IcebergSinkConfig…
Error message
The method start(Catalog, IcebergSinkConfig, SinkTaskContext) is deprecated and will be removed in 2.0.0. Use start(Catalog, IcebergSinkConfig, SinkTaskContext, Collection<TopicPartition>) instead.
What it means
CommitterImpl implements the deprecated 3-argument Committer.start method and deliberately throws UnsupportedOperationException to force migration to the 4-argument overload that receives the currently assigned TopicPartitions. The deprecated entry point cannot work correctly with the partition-based worker lifecycle the sink now uses. This is a hard-stop guard, not a graceful deprecation.
Solutions
- Call the 4-argument overload start(Catalog, IcebergSinkConfig, SinkTaskContext, Collection<TopicPartition>) passing the partitions currently assigned to the task.
- If invoked indirectly by the Connect framework, upgrade the Iceberg sink connector (and Kafka Connect runtime) to versions that agree on the new interface.
- If you maintain a wrapper or subclass of CommitterImpl, forward to the new overload instead of the deprecated one.
Example fix
// before committer.start(catalog, sinkConfig, sinkTaskContext); // after committer.start(catalog, sinkConfig, sinkTaskContext, context.assignment());
Defensive patterns
Strategy: validation
Validate before calling
// Java
if (partitions == null) {
throw new IllegalArgumentException("partitions collection required: use the 4-arg start overload");
}
committer.start(catalog, sinkConfig, sinkTaskContext, partitions); Try / catch
try { committer.start(catalog, cfg, ctx, partitions); } catch (UnsupportedOperationException e) { throw new IllegalStateException("Connector/framework version mismatch on Committer API", e); } Prevention
- Always call the 4-argument start overload in new code
- Keep the Iceberg sink connector and Kafka Connect runtime versions aligned
- Watch deprecation warnings at compile time (-Werror or lint) to catch legacy API usage
When it happens
Trigger: Kafka Connect's worker calls the old Committer.start(Catalog, IcebergSinkConfig, SinkTaskContext) overload — i.e. running an Iceberg sink connector version whose Committer interface still exposes the 3-arg start against this implementation, typically a version-mismatch between connector code and Connect framework or an externally constructed Committer invoking the legacy method.
Common situations: Upgrading the Iceberg Kafka Connect sink while a custom or patched Connect runtime still binds to the legacy SenderTask/Committer signatures; building a custom channel implementation that calls start() without the assigned partitions collection.
Understand the failure class
Background: "is deprecated and will be removed" — deprecation warnings for old API names, keywords, and options, and how to migrate before the removal release — this error's family across 29 libraries.
Related errors
- The method stop() is deprecated and will be removed in…
- Altering schema is not supported in the old alterTable API…
- Cannot convert type
- Incremental scan is not supported
- Server does not support endpoint
AI-assisted analysis of apache/iceberg@86d9c8fc54 (2026-09-12).
Data as JSON: /api/errors/1e1405ca34dc92d3.
Report an issue: GitHub.
Appendix: source
Thrown at kafka-connect/kafka-connect/src/main/java/org/apache/iceberg/connect/channel/CommitterImpl.java:135
}
return containsFirst;
}
@VisibleForTesting
TopicPartition findFirstTopicPartition(Collection<MemberDescription> members) {
return members.stream()
.flatMap(member -> member.assignment().topicPartitions().stream())
.min(new TopicPartitionComparator())
.orElse(null);
}
@Override
public void start(
Catalog icebergCatalog,
IcebergSinkConfig icebergSinkConfig,
SinkTaskContext sinkTaskContext) {
throw new UnsupportedOperationException(
"The method start(Catalog, IcebergSinkConfig, SinkTaskContext) is deprecated and will be removed in 2.0.0. "
+ "Use start(Catalog, IcebergSinkConfig, SinkTaskContext, Collection<TopicPartition>) instead.");
}
@Override
public void open(
Catalog icebergCatalog,
IcebergSinkConfig icebergSinkConfig,
SinkTaskContext sinkTaskContext,
Collection<TopicPartition> addedPartitions) {
initialize(icebergCatalog, icebergSinkConfig, sinkTaskContext);
if (hasLeaderPartition(addedPartitions)) {
LOG.info("Committer {} received leader partition. Starting Coordinator.", taskId);
startCoordinator();
}
}
@OverrideView on GitHub (pinned to 86d9c8fc54)