You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by "clintropolis (via GitHub)" <gi...@apache.org> on 2023/06/27 03:31:20 UTC

[GitHub] [druid] clintropolis commented on a diff in pull request #14124: Cache parsed expressions and binding analysis in more places.

clintropolis commented on code in PR #14124:
URL: https://github.com/apache/druid/pull/14124#discussion_r1243099086


##########
sql/src/main/java/org/apache/druid/sql/calcite/expression/OperatorConversions.java:
##########
@@ -303,7 +303,7 @@ public static PostAggregator toPostAggregator(
             postAggregatorVisitor.getOutputNamePrefix() + postAggregatorVisitor.getAndIncrementCounter(),
             druidExpression.getExpression(),
             null,
-            plannerContext.getExprMacroTable()
+            plannerContext.parse(druidExpression.getExpression())

Review Comment:
   nit: am conflicted, this reads funny like it isn't obvious at a glance it is parsing native expressions since like why would that be built-in to the plannerContext, otoh it would be hella tedious to always be `plannerContext.getExpressionParser().parse(...)` all the time..



-- 
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: commits-unsubscribe@druid.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org