StarRocks / starrocks

StarRocks, a Linux Foundation project, is a next-generation sub-second MPP OLAP database for full analytics scenarios, including multi-dimensional analytics, real-time analytics, and ad-hoc queries.
https://starrocks.io
Apache License 2.0
8.65k stars 1.75k forks source link

【BUG】Profile does not record while querinh the hive partitions that do not exist #49817

Open mlbzssk opened 4 weeks ago

mlbzssk commented 4 weeks ago

Steps to reproduce the behavior (Required)

1、HIVE node execute: CREATE TABLE sales (
product_id INT,
product_name STRING ) PARTITIONED BY (sale_year INT, sale_month INT) ROW FORMAT DELIMITED
FIELDS TERMINATED BY ','
STORED AS TEXTFILE
LOCATION 'xxxxx';

2、starrocks fe execute: CREATE EXTERNAL CATALOG hive_catalog_test PROPERTIES ("hive.metastore.type" = "hive", "hive.metastore.uris" = "thrift://ip:7004", "type" = "hive" )

set enable_profile=true;select * from sales where sale_year=2023 and sale_month=1;

you can not get the profile in the web ui

This may be the cause of the problem: image image If isProfileEnabled, the task should be accept even through It's executed in FE.

Expected behavior (Required)

get the profile info

Real behavior (Required)

StarRocks version (Required)

3.3.2-8151398

mlbzssk commented 4 weeks ago

If I'm locating the problem correctly, I'll fix it

before-Sunrise commented 4 weeks ago

if this sql use FeExecuteCoordinator, then it will not have profile right now. you can add profile for FeExecuteCoordinator. Our Profile has some levels: Query: Summary: Planner: Execution: Execution is Be's profile, which is not need for FeExecuteCoordinator. so you can keey other profiles which are built in StmeExecutor::buildTopLevelProfile