apache/beam · error · UnsupportedOperationException

Unsupported vector type: <type.getClass()>

Error message

Unsupported vector type: <type.getClass()>

What it means

getVectorValue() converts columnar ColumnVector data into Beam values for known DataType variants; for any unrecognized DataType it throws UnsupportedOperationException with the vector's type class. This is the columnar-path equivalent of getFieldValue()'s unsupported-type error.

Source

Thrown at sdks/java/io/delta/src/main/java/org/apache/beam/sdk/io/delta/DeltaSourceDoFn.java:376

      for (int i = 0; i < size; i++) {
        Object key = getVectorValue(keys, i, keyType);
        if (key != null) {
          map.put(key, getVectorValue(values, i, valueType));
        }
      }
      return map;
    } else if (type instanceof StructType) {
      StructType structType = (StructType) type;
      int numFields = structType.fields().size();
      ColumnVector[] childVectors = new ColumnVector[numFields];
      for (int i = 0; i < numFields; i++) {
        childVectors[i] = vector.getChild(i);
      }
      io.delta.kernel.data.Row nestedRow = new VectorRow(structType, childVectors, index);
      Schema nestedBeamSchema = DeltaIO.ReadRows.convertToBeamSchema(structType);
      return toBeamRow(nestedRow, nestedBeamSchema);
    }
    throw new UnsupportedOperationException("Unsupported vector type: " + type.getClass());
  }

  // A new new Delta Row type to efficiently convert columnar data from Delta Lake
  // to Beam Rows. We use this to store columnar vectors without creating
  // additinal memory copies for all fields but return values of the specific
  // row index.
  private static class VectorRow implements io.delta.kernel.data.Row {
    private final StructType schema;
    private final ColumnVector[] fields;
    private final int rowIndex;

    VectorRow(StructType schema, ColumnVector[] fields, int rowIndex) {
      this.schema = schema;
      this.fields = fields;
      this.rowIndex = rowIndex;
    }

    @Override

View on GitHub (pinned to 12126d8942)

Solutions

  1. Upgrade Beam Delta IO connector and io.delta kernel dependencies to support the column's type
  2. Identify the offending column from the schema and its DataType
  3. Rewrite/ETL the table casting that column into a supported type
  4. Restrict the read to supported columns if the API surface allows projection

Example fix

// before
// reading a table whose new Delta type has no vector mapping
PCollection<Row> rows = input.apply(DeltaIO.read().withTable(path).withStartVersion(0L));
// after
// upgrade dependencies, e.g.
// implementation 'org.apache.beam:beam-sdks-java-io-delta:<latest>'
// implementation 'io.delta:delta-kernel-api:<latest>'
// implementation 'io.delta:delta-kernel-defaults:<latest>'
Defensive patterns

Strategy: validation

Validate before calling

// Same preflight as getFieldValue: verify all column types map to supported Beam types
for (StructField f : snapshot.getSchema().fields()) {
  if (!isSupportedBeamMapping(f.getDataType())) {
    throw new IllegalStateException("Column " + f.getName() + " uses unsupported vector type " + f.getDataType());
  }
}

Try / catch

try {
  rows = input.apply(deltaIO);
} catch (UnsupportedOperationException e) {
  if (e.getMessage().startsWith("Unsupported vector type:")) {
    // upgrade connector/kernel or rewrite the column to a supported type
  } else { throw e; }
}

Prevention

When it happens

Trigger: During processElement, a Parquet column vector whose Delta DataType is not among the supported primitives/complex types is converted while materializing Beam Rows.

Common situations: Tables using newer Delta types the connector doesn't map; Parquet-encoded columns with types outside the supported set; version skew between delta kernel, parquet-mr, and the Beam connector.

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


AI-assisted analysis of apache/beam@12126d8942 (2026-09-13). Data as JSON: /api/errors/bb215c571cb307ce. Report an issue: GitHub.