bkietz commented on a change in pull request #10705:
URL: https://github.com/apache/arrow/pull/10705#discussion_r668226804



##########
File path: cpp/src/arrow/compute/exec/exec_plan.h
##########
@@ -243,12 +244,17 @@ ExecNode* MakeSourceNode(ExecPlan* plan, std::string 
label,
 
 /// \brief Add a sink node which forwards to an AsyncGenerator<ExecBatch>
 ///
-/// Emitted batches will not be ordered; instead they will be tagged with the 
`seq` at
-/// which they were received.
+/// Emitted batches will not be ordered.
 ARROW_EXPORT
 std::function<Future<util::optional<ExecBatch>>()> MakeSinkNode(ExecNode* 
input,
                                                                 std::string 
label);
 
+/// \brief Add a sink node which forwards to a RecordBatchReader
+///
+/// Emitted batches will not be ordered.
+ARROW_EXPORT
+std::shared_ptr<RecordBatchReader> MakeSinkNodeReader(ExecNode* input, 
std::string label);

Review comment:
       Dataset scans can preserve ordering based on fragment/batch index, but 
this is only possible for graphs which don't include a pipeline breaker. I 
could provide `BatchGen dataset::BatchesInOrder(BatchGen)` to apply 
fragment/batch ordering if possible.
   
   This is mostly here to provide for non-async consumption of an ExecPlan and 
to avoid requiring R to write bindings for ExecBatch




-- 
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]


Reply via email to