Skip to content

make udf structs public #9900

@universalmind303

Description

@universalmind303

Is your feature request related to a problem or challenge?

Datafusion 36 changed a lot of the builtinfunction stuff, mainly to make it more modular for which functions you want to register, while this is great, it does impose some limitations on end users.

For example in GlareDB, we build out a catalog entry for each of the datafusion functions. (a trait that provides some additional functionality on top of what's provided by datafusion).

trait CatalogEntry {
    const NAME: &'static str;
    const DESCRIPTION: &'static str;
    const EXAMPLE: &'static str;
    const FUNCTION_TYPE: FunctionType = FunctionType::Scalar;
}

Currently (datafusion 35) we just create a new struct similar to what is already done in the datafusion/functions crate, but to reduce duplicated code, we'd like to just implement it directly on the structs

impl CatalogEntry for ArrayToString {
// ...
}

Describe the solution you'd like

all function structs in datafusion/functions and datafusion/functions-array are public.

Describe alternatives you've considered

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions