alamb opened a new issue, #15319: URL: https://github.com/apache/datafusion/issues/15319
### Is your feature request related to a problem or challenge? Creating a `DiskManager` today is somewhat awkward as described by @2010YOUY01 in https://github.com/apache/datafusion/pull/14975#discussion_r1977146593 It would be nice to follow the builder pattern that is used elsewhere in DataFusion such a [`RuntimeEnvBuilder`](https://docs.rs/datafusion/latest/datafusion/execution/runtime_env/struct.RuntimeEnvBuilder.html) -- see [example](https://docs.rs/datafusion/latest/datafusion/execution/runtime_env/struct.RuntimeEnv.html) ### Describe the solution you'd like I would like to have an API that looks like this (the `with_max_temp_directory_size` is part of https://github.com/apache/datafusion/pull/14975) ```rust let manager: Arc<DiskManager> = DiskManagerBuilder::new() .with_max_temp_directory_size(100*1024*1024) .build_arc(); ``` ### Describe alternatives you've considered I suggest: 1. Renaming `DiskManagerConfig` to `DiskManagerBuilder` 2. Leave a backwards compatible deprecated type (like is here https://github.com/apache/datafusion/blob/8e2bfa474743e83ad31070410328f6b39d213361/datafusion/execution/src/runtime_env.rs#L165-L166) 3. Deprecate `DiskManager::try_new` 4. Add documentation example on DiskManager, similarly to the [example](https://docs.rs/datafusion/latest/datafusion/execution/runtime_env/struct.RuntimeEnv.html) on RuntimeEnv ### Additional context _No response_ -- 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: github-unsubscr...@datafusion.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org