mchades opened a new pull request, #9560: URL: https://github.com/apache/gravitino/pull/9560
### What changes were proposed in this pull request? This PR implements the core operations for UDF (User-Defined Function) management in Gravitino, including: **ManagedFunctionOperations implementation:** - `registerFunction`: Register scalar, aggregate, and table functions with multi-definition support - `getFunction`: Retrieve function by identifier (latest version) - `listFunctions`: List all functions in a schema namespace - `alterFunction`: Apply changes to existing functions with proper validations - `dropFunction`: Remove a function **FunctionChange validations:** - `AddDefinition`: Validates no arity overlap with existing definitions to prevent ambiguous function invocations - `RemoveDefinition`: Ensures the definition exists and is not the only one (use dropFunction instead) - `AddImpl`: Validates the definition exists and runtime is unique within the definition - `UpdateImpl`: Validates both definition and runtime exist - `RemoveImpl`: Validates impl exists and is not the only one (use removeDefinition instead) **Unit tests:** - Added comprehensive unit tests for ManagedFunctionOperations with 20 test cases covering all CRUD operations and validation scenarios ### Why are the changes needed? This is part of the UDF management feature for Gravitino. The core operations layer provides the business logic for function management, ensuring data integrity through proper validations. ### Does this PR introduce _any_ user-facing change? No, this is an internal implementation. ### How was this patch tested? Added unit tests in `TestManagedFunctionOperations.java` covering: - Function registration and listing - Function retrieval (get) - Function deletion (drop) - All FunctionChange operations with validation - Version increment behavior - Error cases for invalid operations -- 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]
