Skip to content

Commit

Permalink
1
Browse files Browse the repository at this point in the history
  • Loading branch information
liuyehcf committed Oct 30, 2023
1 parent 20e264f commit 7dd9145
Showing 1 changed file with 2 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,6 @@ public static MaterializedViewRewriteMode parse(String str) {
public static final String BIG_QUERY_LOG_CPU_SECOND_THRESHOLD = "big_query_log_cpu_second_threshold";
public static final String BIG_QUERY_LOG_SCAN_BYTES_THRESHOLD = "big_query_log_scan_bytes_threshold";
public static final String BIG_QUERY_LOG_SCAN_ROWS_THRESHOLD = "big_query_log_scan_rows_threshold";
public static final String ENABLE_BIG_QUERY_PROFILE = "enable_big_query_profile";
public static final String BIG_QUERY_PROFILE_SECOND_THRESHOLD = "big_query_profile_second_threshold";

public static final String SQL_DIALECT = "sql_dialect";
Expand Down Expand Up @@ -849,11 +848,8 @@ public static MaterializedViewRewriteMode parse(String str) {
@VariableMgr.VarAttr(name = ENABLE_ASYNC_PROFILE, flag = VariableMgr.INVISIBLE)
private boolean enableAsyncProfile = true;

@VariableMgr.VarAttr(name = ENABLE_BIG_QUERY_PROFILE)
private boolean enableBigQueryProfile = false;

@VariableMgr.VarAttr(name = BIG_QUERY_PROFILE_SECOND_THRESHOLD)
private int bigQueryProfileSecondThreshold = 30;
private int bigQueryProfileSecondThreshold = 0;

@VariableMgr.VarAttr(name = RESOURCE_GROUP_ID, alias = RESOURCE_GROUP_ID_V2,
show = RESOURCE_GROUP_ID_V2, flag = VariableMgr.INVISIBLE)
Expand Down Expand Up @@ -1662,7 +1658,7 @@ public void setEnableLoadProfile(boolean enableLoadProfile) {
}

public boolean isEnableBigQueryProfile() {
return enableBigQueryProfile;
return bigQueryProfileSecondThreshold > 0;
}

public int getBigQueryProfileSecondThreshold() {
Expand Down Expand Up @@ -2794,7 +2790,6 @@ public TQueryOptions toThrift() {
tResult.setQuery_timeout(Math.min(Integer.MAX_VALUE / 1000, queryTimeoutS));
tResult.setQuery_delivery_timeout(Math.min(Integer.MAX_VALUE / 1000, queryDeliveryTimeoutS));
tResult.setEnable_profile(enableProfile);
tResult.setEnable_big_query_profile(enableBigQueryProfile);
tResult.setBig_query_profile_second_threshold(bigQueryProfileSecondThreshold);
tResult.setRuntime_profile_report_interval(runtimeProfileReportInterval);
tResult.setBatch_size(chunkSize);
Expand Down

0 comments on commit 7dd9145

Please sign in to comment.