ParallelIterator is using too much memory
ParallelIterator launches multiple threads to read manifest files and store the entries in an unbounded queue. For large tables (~ 2 million data files in our example), planning files can easily lead to full GC or OOM, especially when column stats is included. We verified that switching to a bounded blocking queue can solve the problem.
By analyzing the heap dump, we also noticed some memory inefficiency regarding how column stats is stored. E.g. object overhead ratio is high because there's a map for each single metric.
Looks like same issue as reported : https://github.com/apache/iceberg/pull/4596
This issue has been automatically marked as stale because it has been open for 180 days with no activity. It will be closed in next 14 days if no further activity occurs. To permanently prevent this issue from being considered stale, add the label 'not-stale', but commenting on the issue is preferred when possible.
This issue has been closed because it has not received any activity in the last 14 days since being marked as 'stale'