apache/iceberg · error · UnsupportedOperationException
readDoubles is not supported
Error message
readDoubles is not supported
What it means
readDoubles(total, vec, rowId) is the batch double read on VectorizedValuesReader; its default body throws UnsupportedOperationException. Concrete readers override it to bulk-decode doubles into an Arrow Float8Vector. When nextVals() reaches the default implementation, the active reader class does not implement bulk double decoding.
Source
Thrown at arrow/src/main/java/org/apache/iceberg/arrow/vectorized/parquet/VectorizedValuesReader.java:100
/** Read `total` integers into `vec` starting at `vec[rowId]` */
default void readIntegers(int total, FieldVector vec, int rowId) {
throw new UnsupportedOperationException("readIntegers is not supported");
}
/** Read `total` longs into `vec` starting at `vec[rowId]` */
default void readLongs(int total, FieldVector vec, int rowId) {
throw new UnsupportedOperationException("readLongs is not supported");
}
/** Read `total` floats into `vec` starting at `vec[rowId]` */
default void readFloats(int total, FieldVector vec, int rowId) {
throw new UnsupportedOperationException("readFloats is not supported");
}
/** Read `total` doubles into `vec` starting at `vec[rowId]` */
default void readDoubles(int total, FieldVector vec, int rowId) {
throw new UnsupportedOperationException("readDoubles is not supported");
}
/**
* Initialize the reader from a page. See {@link ValuesReader#initFromPage(int,
* ByteBufferInputStream)}.
*/
void initFromPage(int valueCount, ByteBufferInputStream in) throws IOException;
}
View on GitHub (pinned to 86d9c8fc54)
Solutions
- Disable vectorized reads (read.arrow.enabled=false) so doubles go through the standard reader.
- Upgrade Iceberg to a release with vectorized double batch support.
- Override readDoubles() in the concrete reader to fill vec[rowId..rowId+total).
Example fix
// before
// default readDoubles throws
// after
@Override
public void readDoubles(int total, FieldVector vec, int rowId) {
for (int i = 0; i < total; i++) ((Float8Vector) vec).setSafe(rowId + i, readDouble());
} Defensive patterns
Strategy: try-catch
Validate before calling
// check double support before enabling vectorization
if (schema.columns().stream().anyMatch(c -> c.type().equals(Types.DoubleType.get())) && !doublesBatchSupported) {
props.put("read.arrow.enabled", "false");
} Try / catch
try {
vectorizedScan();
} catch (UnsupportedOperationException e) {
rowScan();
} Prevention
- Verify readDoubles is overridden in whatever reader your reader factory instantiates.
- Test vectorized scans over every double column before rollout.
- Upgrade Iceberg when vectorized double batch reads are required.
When it happens
Trigger: nextVals(total) attempts to bulk-fill a double Arrow vector for a Parquet DOUBLE column while the selected reader subclass has no readDoubles() override.
Common situations: Vectorized scans of double columns on Iceberg versions whose reader only implements numeric batch paths for integers/longs; pages with encodings lacking a dedicated batch reader; custom reader implementations.
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
- readIntegers is not supported
- readLongs is not supported
- readFloats is not supported
- readLong is not supported
- readFloat is not supported
AI-assisted analysis of apache/iceberg@86d9c8fc54 (2026-09-12).
Data as JSON: /api/errors/97cecd99cbbbf2d4.
Report an issue: GitHub.