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 2021/04/06 06:27:06 UTC

[GitHub] [arrow] Dandandan commented on a change in pull request #9897: ARROW-12214: [Rust][DataFusion] Add tests for limit

Dandandan commented on a change in pull request #9897:
URL: https://github.com/apache/arrow/pull/9897#discussion_r607551532



##########
File path: rust/datafusion/src/execution/context.rs
##########
@@ -1721,6 +1721,46 @@ mod tests {
         Ok(())
     }
 
+    #[tokio::test]
+    async fn limit() -> Result<()> {
+        let tmp_dir = TempDir::new()?;
+        let mut ctx = create_ctx(&tmp_dir, 1)?;
+        ctx.register_table("t", table_with_sequence(1, 1000).unwrap())

Review comment:
       I was looking at `Limit` yesterday - it seems to poll new batches even when the limit has been reached (and throw away the result in the end)? Not wrong - but quite inefficient of course :) 




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

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