physicalplan: avoid serialization of expressions on the gateway in distributed flows #49810
Labels
A-sql-execution
Relating to SQL execution.
C-enhancement
Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)
Currently we do expression serialization on all nodes, including the gateway, if the flow is distributed: in
MakeExpression
we callctx.IsLocal()
to decide whether we should serialize the expression, and that call returnstrue
only whenPlanningCtx.isLocal
istrue
which is the case only when the flow is not distributed. I think we could be smarter and avoid the serialization on the gateway node, but it doesn't seem trivial.The text was updated successfully, but these errors were encountered: