alamb commented on a change in pull request #8032: URL: https://github.com/apache/arrow/pull/8032#discussion_r478319729
########## File path: rust/datafusion/src/logicalplan.rs ########## @@ -1042,6 +998,35 @@ pub fn can_coerce_from(type_into: &DataType, type_from: &DataType) -> bool { } } +/// A registry of functions used to plan queries programmatically Review comment: I wonder if you could implement UDFFactory on `DataFrameImpl` as well -- something like (untested) ``` impl UDFFactory for DataFrameImpl { fn udf(&self, name: &str, args: Vec<Expr>) -> Result<Expr> { self.ctx_state.lock().expect("locked the mutex").udf(name, args) } ``` I think this is another good example of why it would be helpful to remove the the Mutex from ExecutionContextState. I'll keep working on that -- I apologize for my slowness this week. I'll be back full time next week and hopefully make faster progress ---------------------------------------------------------------- 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: us...@infra.apache.org