andygrove opened a new pull request, #4223: URL: https://github.com/apache/datafusion-comet/pull/4223
## Which issue does this PR close? Part of https://github.com/apache/datafusion-comet/issues/4193 ## Rationale for this change This is stacked on #4170 (Comet JVM UDF framework). With that infrastructure in place, adding a new higher-order function required ~200 lines of new code (registry + UDF + serde), demonstrating the framework's extensibility for lambda-based expressions. ## What changes are included in this PR? **Experimental** support for Spark's `exists(array, x -> predicate(x))` — the first lambda-based expression accelerated by Comet. - `CometLambdaRegistry`: static concurrent map bridging plan-time lambda expressions to execution-time UDF lookup - `ArrayExistsUDF`: iterates ListVector elements, evaluates the lambda predicate via Spark's `NamedLambdaVariable`, implements three-valued null logic - `CometArrayExists` serde: registers the lambda, emits `JvmScalarUdf` proto - Scope: single-argument lambdas referencing only the array element; primitive + string element types ## How are these changes tested? 5 end-to-end tests in `CometArrayExpressionSuite` covering integer predicates, string predicates, null elements with three-valued logic, all-match case, and empty arrays. All use `checkSparkAnswerAndOperator` to verify both correctness and native execution. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
