datafusion icon indicating copy to clipboard operation
datafusion copied to clipboard

Add `ParquetExec::builder` API

Open alamb opened this issue 1 year ago • 0 comments

Which issue does this PR close?

Part of #10546

Rationale for this change

While working on https://github.com/apache/datafusion/pull/10549 it cumbersome to create a ParquetExec -- there are a few fields on ParquetExec::new that need default values that make it slightly confusing to use.

What changes are included in this PR?

  1. Add ParquetExecBuilder and ParquetExec::builder() that handle defaults
  2. Add an example
  3. Update the code to use the new API

You can see this in action here #10618

Are these changes tested?

Yes, covered by existing tests and new doc example tests

Are there any user-facing changes?

Better docs / examples / builder. No API changes, though ParquetExec::new() is now deprecated

alamb avatar May 23 '24 12:05 alamb