Details
-
New Feature
-
Status: Resolved
-
Major
-
Resolution: Won't Fix
-
None
-
None
-
None
Description
In practical use, we usually need to create a big iterator, which means too big in `memory usage` or too long in `array size`. On the one hand, it leads to too much memory consumption. On the other hand, one `Array` may not hold all the elements, as java array indices are of type 'int' (4 bytes or 32 bits). So, IMHO, we may provide a `collector`, which has a buffer, 100MB or any others, and could spill data into disk. The use case may like:
rdd.mapPartition { it =>
...
val collector = new ExternalCollector()
collector.collect(a)
...
collector.iterator
}
I have done some related works, and I need your opinions, thanks!
Attachments
Issue Links
- relates to
-
SPARK-6713 Iterators in columnSimilarities to allow flatMap spill
- Resolved