Dandandan commented on code in PR #5161:
URL: https://github.com/apache/arrow-datafusion/pull/5161#discussion_r1097183956


##########
datafusion/core/src/physical_plan/file_format/file_stream.rs:
##########
@@ -98,6 +99,8 @@ enum FileStreamState {
         partition_values: Vec<ScalarValue>,
         /// The reader instance
         reader: BoxStream<'static, Result<RecordBatch, ArrowError>>,
+        /// A [`FileOpenFuture`] for the next file to be processed
+        next: Option<(FileOpenFuture, Vec<ScalarValue>)>,

Review Comment:
   I wonder if we could make it future-proof by potentially prefetching `n` 
files instead of 1? I guess in cases where file opening is slower than scanning 
/ processing, this could make a difference (e.g. small files).



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