Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Their DDLs are “CREATE/DROP TEMPORARY SYSTEM FUNCTION”.

Existing “registerScalar/Table/AggregateFunctions()” will be deprecated in favor of the new APIs.

b) Temporary Functions

We will add a new member variable to FunctionCatalog as “Map<ObjectIdentifier, UserDefinedFunction>  tempFunctions“ to hold those temporary functions in a central place, and new APIs “registerTemporaryScalar/Table/AggregateFunction(ObjectIdentifier, UserDefinedFunction)”. 

...

  1. Temporary system functions
  2. Flink Built-in functions
  3. Temporary functions, in the current catalog and current database of the session
  4. Catalog functions, in the current catalog and current database of the session

The new resolution order will be a breaking change, compared to existing resolution order.

Temp functions should rank above their corresponding persistent/built-in functions due to its temporary nature - users want to overwrite built-in or persistent functions with something temporary that is only visible to themselves and the session, and not impacting other users. In contrary, 1) if users don’t have the intention of overwriting other functions, they can just name the temporary functions to something else, considering the manipulation cost is so low for temporary objects, and 2) if built-in functions precede temporary functions, there’s no way to reference temp functions anymore

...