Backport #72735 to 24.9: Fix context lifetime for Y-shaped join.

This commit is contained in:
robot-clickhouse 2024-12-03 19:09:36 +00:00
parent 1fbcec4308
commit e55aaa6eb6

View File

@ -339,6 +339,7 @@ QueryPipelineBuilderPtr QueryPipelineBuilder::mergePipelines(
left->pipe.processors->insert(left->pipe.processors->end(), right->pipe.processors->begin(), right->pipe.processors->end()); left->pipe.processors->insert(left->pipe.processors->end(), right->pipe.processors->begin(), right->pipe.processors->end());
left->pipe.header = left->pipe.output_ports.front()->getHeader(); left->pipe.header = left->pipe.output_ports.front()->getHeader();
left->pipe.max_parallel_streams = std::max(left->pipe.max_parallel_streams, right->pipe.max_parallel_streams); left->pipe.max_parallel_streams = std::max(left->pipe.max_parallel_streams, right->pipe.max_parallel_streams);
left->resources = std::move(right->resources);
return left; return left;
} }