This is an automated email from the ASF dual-hosted git repository.

zhangzc pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-gluten.git


The following commit(s) were added to refs/heads/main by this push:
     new 42f65807f8 [MINOR][CH] Refactor extraExpressionConverter for 
CHSparkPlanExecApi (#10694)
42f65807f8 is described below

commit 42f65807f89467ed894afbf9e3dd85624985613b
Author: Jiaan Geng <[email protected]>
AuthorDate: Mon Sep 15 10:28:25 2025 +0800

    [MINOR][CH] Refactor extraExpressionConverter for CHSparkPlanExecApi 
(#10694)
    
    [CH] Refactor extraExpressionConverter for CHSparkPlanExecApi
---
 .../backendsapi/clickhouse/CHSparkPlanExecApi.scala       | 15 +++++----------
 1 file changed, 5 insertions(+), 10 deletions(-)

diff --git 
a/backends-clickhouse/src/main/scala/org/apache/gluten/backendsapi/clickhouse/CHSparkPlanExecApi.scala
 
b/backends-clickhouse/src/main/scala/org/apache/gluten/backendsapi/clickhouse/CHSparkPlanExecApi.scala
index 6b42bfc9ae..44d58e4747 100644
--- 
a/backends-clickhouse/src/main/scala/org/apache/gluten/backendsapi/clickhouse/CHSparkPlanExecApi.scala
+++ 
b/backends-clickhouse/src/main/scala/org/apache/gluten/backendsapi/clickhouse/CHSparkPlanExecApi.scala
@@ -607,16 +607,11 @@ class CHSparkPlanExecApi extends SparkPlanExecApi with 
Logging {
   override def extraExpressionConverter(
       substraitExprName: String,
       expr: Expression,
-      attributeSeq: Seq[Attribute]): Option[ExpressionTransformer] = expr 
match {
-    case e if 
ExpressionExtensionTrait.findExpressionExtension(e.getClass).nonEmpty =>
-      // Use extended expression transformer to replace custom expression first
-      Some(
-        ExpressionExtensionTrait
-          .findExpressionExtension(e.getClass)
-          .get
-          .replaceWithExtensionExpressionTransformer(substraitExprName, e, 
attributeSeq))
-    case _ => None
-  }
+      attributeSeq: Seq[Attribute]): Option[ExpressionTransformer] =
+    // Use extended expression transformer to replace custom expression first
+    ExpressionExtensionTrait
+      .findExpressionExtension(expr.getClass)
+      .map(_.replaceWithExtensionExpressionTransformer(substraitExprName, 
expr, attributeSeq))
 
   override def genStringTranslateTransformer(
       substraitExprName: String,


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to