apache/seatunnel · error · UncheckedIOException
Failed to close equality delta writer
Error message
Failed to close equality delta writer
What it means
PartitionedDeltaWriter.close() iterates all wrapped per-partition RowDataDeltaWriters and closes them via a tries-run; if any writer's close throws an IOException it is rethrown as an UncheckedIOException. This indicates the underlying Iceberg write (e.g. closing a parquet/avro file or committing writes to the file IO) failed while finalizing the sink.
Source
Thrown at seatunnel-connectors-v2/connector-iceberg/src/main/java/org/apache/seatunnel/connectors/seatunnel/iceberg/sink/writer/PartitionedDeltaWriter.java:92
PartitionKey copiedKey = partitionKey.copy();
writer = new RowDataDeltaWriter(copiedKey);
writers.put(copiedKey, writer);
}
return writer;
}
@Override
public void close() {
try {
Tasks.foreach(writers.values())
.throwFailureWhenFinished()
.noRetry()
.run(RowDataDeltaWriter::close, IOException.class);
writers.clear();
} catch (IOException e) {
throw new UncheckedIOException("Failed to close equality delta writer", e);
}
}
}
View on GitHub (pinned to cf67b549a7)
Solutions
- Inspect the wrapped IOException (cause) for the real storage/IO error and fix storage connectivity, credentials, or disk space first
- Retry the job; transient storage failures during close are often recoverable from the last checkpoint
- Verify the warehouse/URI config (hdfs path, s3a endpoint) is reachable from all worker nodes
- If reproducible with one file, check for corrupted in-progress write files in the target table location and clean stale files
Defensive patterns
Strategy: retry
Validate before calling
// ensure target storage is reachable before submitting // hdfs dfs -test -e <warehouse.path> || s3 ls <s3a.warehouse>
Try / catch
// engine-level: rely on checkpoint restart; at API level
try { deltaWriter.close(); } catch (UncheckedIOException e) { log.error("storage close failed", e.getCause()); throw e; } Prevention
- Verify warehouse/storage connectivity and credentials from all worker nodes before submitting
- Monitor disk space and object-store quotas
- Keep checkpoints enabled so transient close failures recover
- Clean stale in-progress files after failed jobs
When it happens
Trigger: Closing the delta writers at sink checkpoint/close time when one of the per-partition writers fails to flush or close its data files (disk full, HDFS/S3 IO failure, corrupted output stream).
Common situations: Underlying object store (S3/HDFS/OSS) outages or credential expiry mid-write; disk quota exhaustion on worker nodes; network interruptions between worker and storage during checkpoint close.
Understand the failure class
Background: "failed to write file", "Could not save figure", "Error saving remote file" — file write failed: causes and fixes across languages and libraries — this error's family across 38 libraries.
Related errors
- WRITER_OPERATION_FAILED
- Cannot convert to BigDecimal:
- Cannot convert to boolean:
- Cannot convert to UUID:
- Cannot convert to binary:
AI-assisted analysis of apache/seatunnel@cf67b549a7 (2026-09-10).
Data as JSON: /api/errors/f4de7928fd89094b.
Report an issue: GitHub.