You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/04/20 21:31:03 UTC

[GitHub] [arrow-datafusion] alamb commented on a diff in pull request #2296: Simplify sort streams

alamb commented on code in PR #2296:
URL: https://github.com/apache/arrow-datafusion/pull/2296#discussion_r854570094


##########
datafusion/core/src/physical_plan/sorts/sort_preserving_merge.rs:
##########
@@ -354,17 +333,13 @@ impl SortPreservingMergeStream {
             .map(|_| VecDeque::new())
             .collect();
         tracking_metrics.init_mem_used(streams.iter().map(|s| s.mem_used).sum());
-        let wrappers = streams
-            .into_iter()
-            .map(|s| StreamWrapper::Stream(Some(s)))
-            .collect();
+        let wrappers = streams.into_iter().map(|s| s.stream.fuse()).collect();

Review Comment:
   Is `fuse` the magic that avoids the need for the stream wrapper?



-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org