apache/seatunnel · error · UnsupportedOperationException
setTypeInfo method is not supported
Error message
setTypeInfo method is not supported
What it means
Sentinel UnsupportedOperationException from the deprecated default SeaTunnelSink.setTypeInfo method: this sink implementation (created via createAndPrepareSink) never overrode the legacy type-info hook. Modern sinks get their row type from the Factory/translation layer instead, so hitting this means the calling translation path is still using the old deprecated API against a sink that only supports the new one.
Solutions
- Rely on the factory-based type discovery (TableSchemaFactory / translation layer) instead of calling setTypeInfo
- If a legacy execution path must be supported, override setTypeInfo in the concrete sink
- Upgrade the translation/entrypoint code to the current API that no longer invokes this method
Defensive patterns
Strategy: type-guard
When it happens
Trigger: Thrown at seatunnel-api/src/main/java/org/apache/seatunnel/api/sink/SeaTunnelSink.java:62 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of apache/seatunnel@cf67b549a7 (2026-09-10).
Data as JSON: /api/errors/2b989998a1df343f.
Report an issue: GitHub.
Appendix: source
Thrown at seatunnel-api/src/main/java/org/apache/seatunnel/api/sink/SeaTunnelSink.java:62
* CommitInfoT}. {@link SinkAggregatedCommitter} handle it, this class should implement
* interface {@link Serializable}.
*/
public interface SeaTunnelSink<IN, StateT, CommitInfoT, AggregatedCommitInfoT>
extends Serializable,
PluginIdentifierInterface,
SeaTunnelPluginLifeCycle,
SeaTunnelJobAware {
/**
* Set the row type info of sink row data. This method will be automatically called by
* translation.
*
* @deprecated instead by {@link org.apache.seatunnel.api.table.factory.Factory}
* @param seaTunnelRowType The row type info of sink.
*/
@Deprecated
default void setTypeInfo(SeaTunnelRowType seaTunnelRowType) {
throw new UnsupportedOperationException("setTypeInfo method is not supported");
}
/**
* Get the data type of the records consumed by this sink.
*
* @deprecated instead by {@link org.apache.seatunnel.api.table.factory.Factory}
* @return SeaTunnel data type.
*/
@Deprecated
default SeaTunnelDataType<IN> getConsumedType() {
throw new UnsupportedOperationException("getConsumedType method is not supported");
}
/**
* This method will be called to creat {@link SinkWriter}
*
* @param context The sink context
* @return Return sink writer instanceView on GitHub (pinned to cf67b549a7)