From 4d5376773ca13ec0deb869278b8ba3f741c4a788 Mon Sep 17 00:00:00 2001 From: yang_feida Date: Wed, 18 Jun 2025 20:13:02 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E5=AF=B9running=E6=80=81?= =?UTF-8?q?=E7=9A=84=E6=A3=80=E6=9F=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- omniadvisor/src/omniadvisor/interface/config_tuning.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/omniadvisor/src/omniadvisor/interface/config_tuning.py b/omniadvisor/src/omniadvisor/interface/config_tuning.py index a8136a3f1..a735c323b 100644 --- a/omniadvisor/src/omniadvisor/interface/config_tuning.py +++ b/omniadvisor/src/omniadvisor/interface/config_tuning.py @@ -179,12 +179,6 @@ def main(): # 1. 存在最近的调优结果 # 2. 调优方法不是用户配置(用户配置无需复测) # 3. 调优结果状态仍在运行中(复测中) - tuning_result_history = get_tuning_result_history(load) - if (tuning_result_history.latest_tuning_result - and tuning_result_history.latest_tuning_result.tuning_record.method != OA_CONF.TuningMethod.user - and tuning_result_history.latest_tuning_result.status == OA_CONF.ExecStatus.running): - global_logger.info('The retest status of latest tuning result is still running, please wait.') - return if args.tuning_method or args.retest_way == OA_CONF.RetestWay.hijacking: try: -- Gitee From ffc712a863a0bceccd046360847645af55c76ca1 Mon Sep 17 00:00:00 2001 From: yang_feida Date: Wed, 18 Jun 2025 20:13:37 +0800 Subject: [PATCH 2/2] =?UTF-8?q?spark-run=E6=8A=A5=E9=94=99=EF=BC=8C?= =?UTF-8?q?=E5=9C=A8=E7=94=A8=E6=88=B7=E6=80=81=E4=B8=8D=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/omniadvisor/service/spark_service/spark_run.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/omniadvisor/src/omniadvisor/service/spark_service/spark_run.py b/omniadvisor/src/omniadvisor/service/spark_service/spark_run.py index d7ce73003..4c03a96ea 100644 --- a/omniadvisor/src/omniadvisor/service/spark_service/spark_run.py +++ b/omniadvisor/src/omniadvisor/service/spark_service/spark_run.py @@ -130,7 +130,7 @@ def _update_trace_from_history_server(exam_record: ExamRecord, application_id: s trace_executor = spark_fetcher.get_spark_executor_by_app(application_id) except HTTPError as httpe: time.sleep(OA_CONF.spark_fetch_trace_interval) - global_logger.debug(f"Cannot access history server: {httpe}") + global_logger.debug(f"Cannot access history server: %s", httpe) continue trace_dict['sql'] = save_trace_data(data=trace_sql, data_dir=OA_CONF.data_dir) trace_dict['stages'] = save_trace_data(data=trace_stages, data_dir=OA_CONF.data_dir) @@ -138,6 +138,7 @@ def _update_trace_from_history_server(exam_record: ExamRecord, application_id: s global_logger.info(f"Fetch Spark execute trace success.") break else: - raise RuntimeError(f'Failed to get App {application_id} trace from {history_server_url}') + global_logger.error(f'Failed to get App %s trace from %s', application_id, history_server_url) + return ExamRecordRepository.update_exam_result(exam_record, trace=trace_dict) -- Gitee