File tree Expand file tree Collapse file tree
fe/fe-core/src/main/java/org/apache/doris/planner Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -504,6 +504,8 @@ void ExecNode::collect_scan_nodes(vector<ExecNode*>* nodes) {
504504 collect_nodes (TPlanNodeType::DATA_GEN_SCAN_NODE , nodes);
505505 collect_nodes (TPlanNodeType::FILE_SCAN_NODE , nodes);
506506 collect_nodes (TPlanNodeType::META_SCAN_NODE , nodes);
507+ collect_nodes (TPlanNodeType::JDBC_SCAN_NODE , nodes);
508+ collect_nodes (TPlanNodeType::ODBC_SCAN_NODE , nodes);
507509}
508510
509511void ExecNode::init_runtime_profile (const std::string& name) {
Original file line number Diff line number Diff line change 100100#include " vec/exec/join/vhash_join_node.h"
101101#include " vec/exec/scan/new_es_scan_node.h"
102102#include " vec/exec/scan/new_file_scan_node.h"
103+ #include " vec/exec/scan/new_jdbc_scan_node.h"
103104#include " vec/exec/scan/new_odbc_scan_node.h"
104105#include " vec/exec/scan/new_olap_scan_node.h"
105106#include " vec/exec/scan/vmeta_scan_node.h"
Original file line number Diff line number Diff line change 3838import org .apache .doris .common .AnalysisException ;
3939import org .apache .doris .common .Pair ;
4040import org .apache .doris .common .UserException ;
41- import org .apache .doris .planner .external .jdbc .JdbcScanNode ;
42- import org .apache .doris .planner .external .odbc .OdbcScanNode ;
4341import org .apache .doris .qe .ConnectContext ;
4442import org .apache .doris .qe .SessionVariable ;
4543import org .apache .doris .thrift .TPartitionType ;
@@ -281,12 +279,8 @@ private PlanFragment createMergeFragment(PlanFragment inputFragment)
281279 * TODO: hbase scans are range-partitioned on the row key
282280 */
283281 private PlanFragment createScanFragment (PlanNode node ) throws UserException {
284- if (node instanceof MysqlScanNode || node instanceof OdbcScanNode || node instanceof JdbcScanNode ) {
282+ if (node instanceof MysqlScanNode ) {
285283 return new PlanFragment (ctx .getNextFragmentId (), node , DataPartition .UNPARTITIONED );
286- } else if (node instanceof SchemaScanNode ) {
287- return new PlanFragment (ctx .getNextFragmentId (), node , DataPartition .RANDOM );
288- } else if (node instanceof DataGenScanNode ) {
289- return new PlanFragment (ctx .getNextFragmentId (), node , DataPartition .RANDOM );
290284 } else if (node instanceof OlapScanNode ) {
291285 // olap scan node
292286 OlapScanNode olapScanNode = (OlapScanNode ) node ;
Original file line number Diff line number Diff line change 3838import org .apache .doris .nereids .glue .translator .PlanTranslatorContext ;
3939import org .apache .doris .planner .PlanNodeId ;
4040import org .apache .doris .planner .external .ExternalScanNode ;
41+ import org .apache .doris .qe .ConnectContext ;
4142import org .apache .doris .statistics .StatisticalType ;
4243import org .apache .doris .statistics .StatsRecursiveDerive ;
4344import org .apache .doris .statistics .query .StatsDelta ;
@@ -272,7 +273,8 @@ protected String debugString() {
272273
273274 @ Override
274275 public int getNumInstances () {
275- return 1 ;
276+ return ConnectContext .get ().getSessionVariable ().getEnablePipelineEngine ()
277+ ? ConnectContext .get ().getSessionVariable ().getParallelExecInstanceNum () : 1 ;
276278 }
277279
278280 @ Override
Original file line number Diff line number Diff line change 3232import org .apache .doris .planner .PlanNodeId ;
3333import org .apache .doris .planner .external .ExternalScanNode ;
3434import org .apache .doris .planner .external .jdbc .JdbcScanNode ;
35+ import org .apache .doris .qe .ConnectContext ;
3536import org .apache .doris .statistics .StatisticalType ;
3637import org .apache .doris .statistics .StatsRecursiveDerive ;
3738import org .apache .doris .statistics .query .StatsDelta ;
@@ -213,4 +214,10 @@ public StatsDelta genStatsDelta() throws AnalysisException {
213214 Env .getCurrentEnv ().getCurrentCatalog ().getDbOrAnalysisException (tbl .getQualifiedDbName ()).getId (),
214215 tbl .getId (), -1L );
215216 }
217+
218+ @ Override
219+ public int getNumInstances () {
220+ return ConnectContext .get ().getSessionVariable ().getEnablePipelineEngine ()
221+ ? ConnectContext .get ().getSessionVariable ().getParallelExecInstanceNum () : 1 ;
222+ }
216223}
You can’t perform that action at this time.
0 commit comments