alamb commented on code in PR #5497:
URL: https://github.com/apache/arrow-datafusion/pull/5497#discussion_r1127907690


##########
datafusion/core/src/execution/context.rs:
##########
@@ -2097,27 +2097,28 @@ pub struct TaskContext {
 
 impl TaskContext {
     /// Create a new task context instance
-    pub fn new(
+    pub fn try_new(

Review Comment:
   👍  for the change to make this fallible 



##########
datafusion/common/src/config.rs:
##########
@@ -397,6 +397,13 @@ impl ConfigOptions {
         Self::default()
     }
 
+    /// Creates a new [`ConfigOptions`] with extensions set to provided value
+    pub fn with_extensions(extensions: Extensions) -> Self {

Review Comment:
   What would you think about making this a builder style API?
   
   Like
   
   ```suggestion
       pub fn with_extensions(mut self, extensions: Extensions) -> Self {
   ```
   
   So one could modify an existing ConfigOptions like:
   
   ```rust
   let options = ConfigOptions::new()
     .with_extensions(extensions)
   ```



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