From 9e79488a77dfee06ca920971ab673c5ef682fee7 Mon Sep 17 00:00:00 2001 From: Jiefan Li Date: Wed, 21 Aug 2024 15:15:43 -0400 Subject: [PATCH] [Coral-Trino] Map some UDFs to Trino UDF (#524) --- .../trino/rel2trino/CoralToTrinoSqlCallConverter.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/coral-trino/src/main/java/com/linkedin/coral/trino/rel2trino/CoralToTrinoSqlCallConverter.java b/coral-trino/src/main/java/com/linkedin/coral/trino/rel2trino/CoralToTrinoSqlCallConverter.java index cd3a29bf2..1ff562e01 100644 --- a/coral-trino/src/main/java/com/linkedin/coral/trino/rel2trino/CoralToTrinoSqlCallConverter.java +++ b/coral-trino/src/main/java/com/linkedin/coral/trino/rel2trino/CoralToTrinoSqlCallConverter.java @@ -122,6 +122,15 @@ protected SqlCall transform(SqlCall sqlCall) { "com.linkedin.stdudfs.urnextractor.hive.UrnExtractorFunctionWrapper", 1, "urn_extractor"), new CoralRegistryOperatorRenameSqlCallTransformer( "com.linkedin.stdudfs.hive.daliudfs.UrnExtractorFunctionWrapper", 1, "urn_extractor"), + new CoralRegistryOperatorRenameSqlCallTransformer("com.linkedin.groot.runtime.udf.spark.HasMemberConsentUDF", 3, + "has_member_consent"), + new CoralRegistryOperatorRenameSqlCallTransformer("com.linkedin.groot.runtime.udf.spark.RedactFieldIfUDF", 4, + "urn_extractor"), + new CoralRegistryOperatorRenameSqlCallTransformer( + "com.linkedin.groot.runtime.udf.spark.RedactSecondarySchemaFieldIfUDF", 5, + "redact_secondary_schema_field_if"), + new CoralRegistryOperatorRenameSqlCallTransformer("com.linkedin.groot.runtime.udf.spark.GetMappedValueUDF", 2, + "get_mapped_value"), new GenericCoralRegistryOperatorRenameSqlCallTransformer(), new ReturnTypeAdjustmentTransformer(configs), new UnnestOperatorTransformer(), new AsOperatorTransformer(),