Skip to content

DataFrame.collect() should return async stream rather than a Vec<RecordBatch> #47

Closed

Description

@andygrove

Is your feature request related to a problem or challenge? Please describe what you are trying to do.
Currently, any DataFrame implementation must load the entire result set into RAM in the collect() method because it has to return a Vec<RecordBatch>.

Describe the solution you'd like
Change the signature to return an async stream of batches.

Describe alternatives you've considered
None

Additional context
None

Activity

  1. kination commented on May 16, 2021

    @kination
    Contributor

    @andygrove hope to touch on this if it's not on work yet 🙏

  2. kination commented on May 23, 2021

    @kination
    Contributor

    @andygrove currently collect is collecting SendableRecordBatchStream to Vector inside function before returning.

    let it: SendableRecordBatchStream = plan.execute(0).await?;
    common::collect(it).await
    

    Are you intend to make this not collecting before return?

  3. added a commit that references this issue on Nov 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions