fix bug: plan stat incorrect when some error happened during query processing

This commit is contained in:
obdev
2024-02-09 07:25:50 +00:00
committed by ob-robot
parent b606f00000
commit 6d5c70d2b4
3 changed files with 4 additions and 5 deletions

View File

@ -478,7 +478,8 @@ void ObPhysicalPlan::update_plan_stat(const ObAuditRecordData &record,
if (record.is_timeout()) {
ATOMIC_INC(&(stat_.timeout_count_));
ATOMIC_AAF(&(stat_.total_process_time_), record.get_process_time());
} else if (!GCONF.enable_perf_event) { // short route
}
if (!GCONF.enable_perf_event) { // short route
ATOMIC_AAF(&(stat_.elapsed_time_), record.get_elapsed_time());
ATOMIC_AAF(&(stat_.cpu_time_), record.get_elapsed_time() - record.exec_record_.wait_time_end_
- (record.exec_timestamp_.run_ts_ - record.exec_timestamp_.receive_ts_));