You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "pvary (via GitHub)" <gi...@apache.org> on 2025/12/01 10:45:30 UTC
Re: [PR] Spark: Move DeleteFiltering out from the vectorized reader [iceberg]
pvary commented on code in PR #14652:
URL: https://github.com/apache/iceberg/pull/14652#discussion_r2576567170
##########
spark/v4.0/spark/src/main/java/org/apache/iceberg/spark/source/BaseBatchReader.java:
##########
@@ -67,17 +75,27 @@ protected CloseableIterable<ColumnarBatch> newBatchIterable(
Expression residual,
Map<Integer, ?> idToConstant,
SparkDeleteFilter deleteFilter) {
+ CloseableIterable<ColumnarBatch> iterable;
switch (format) {
case PARQUET:
- return newParquetIterable(inputFile, start, length, residual, idToConstant, deleteFilter);
-
+ iterable =
+ newParquetIterable(
+ inputFile,
+ start,
+ length,
+ residual,
+ idToConstant,
+ deleteFilter != null ? deleteFilter.requiredSchema() : expectedSchema());
+ break;
case ORC:
- return newOrcIterable(inputFile, start, length, residual, idToConstant);
-
+ iterable = newOrcIterable(inputFile, start, length, residual, idToConstant);
+ break;
default:
throw new UnsupportedOperationException(
"Format: " + format + " not supported for batched reads");
}
+
+ return CloseableIterable.transform(iterable, new BatchDeleteFilter(deleteFilter)::filterBatch);
Review Comment:
I hadn’t planned to introduce any new features in this PR, but based on your request, I also updated the ORC implementation and added additional tests.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org