rdblue commented on a change in pull request #3120:
URL: https://github.com/apache/iceberg/pull/3120#discussion_r742122237
##########
File path: core/src/main/java/org/apache/iceberg/AllDataFilesTable.java
##########
@@ -128,9 +127,9 @@ public long targetSplitSize() {
}
private static CloseableIterable<ManifestFile>
allDataManifestFiles(List<Snapshot> snapshots) {
- try (CloseableIterable<ManifestFile> iterable = new ParallelIterable<>(
- Iterables.transform(snapshots, snapshot -> (Iterable<ManifestFile>) ()
-> snapshot.dataManifests().iterator()),
- ThreadPools.getWorkerPool())) {
+ try (CloseableIterable<ManifestFile> iterable = CloseableIterable.combine(
+ Iterables.transform(snapshots, snapshot ->
CloseableIterable.withNoopClose(snapshot.dataManifests())),
Review comment:
This does need to be fixed. `ParallelIterable` was constructed using
`Iterable<? extends Iterable<T>>`. There should be a version of
`CloseableIterable.combine` that accepts the same type. That may mean updating
`CloseableIterable.concat` to accept the same `? extends Iterable<T>` in
addition to strictly a `CloseableIterable<T>`. But that should be okay, since
you can update to close the iterable if it is closeable.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]