rtpsw commented on PR #13375:
URL: https://github.com/apache/arrow/pull/13375#issuecomment-1153940711

   > @rtpsw I did skim through the PR, interesting!. What is required to get a 
functional test case to evaluate registering a UDF? I went through the JIRA, 
but it is not clear what is meant by
   > 
   > > registering a function (with an Id) external to the plan
   
   You're right, this isn't trivial. The issue is that `Id` is defined with two 
members of type `util::string_view`, which point to strings that must be held 
elsewhere while the plan is in scope. This is satisfied for an `Id` that has 
these fields pointing to strings parsed from the Substrait plan itself. 
However, if a user registers a function with an `Id` whose field values are 
external to the plan, then the strings they point to should be held while the 
plan is in scope, so it makes sense to keep the strings on the plan; this is 
what `AddExternalSymbol` is meant for.
   
   I intend to add test cases a bit later. This PR is an extraction from a 
larger project project I'm working on for end-to-end 
(Ibis/Ibis-Substrait/PyArrow) support for Python-UDFs.


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