From 9dad8cb0a052196039544aa37c115273f13421f2 Mon Sep 17 00:00:00 2001 From: fit2-zhao Date: Thu, 1 Jul 2021 16:28:06 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E8=AE=A1=E5=88=92):=20?= =?UTF-8?q?=E6=80=A7=E8=83=BD=E6=B5=8B=E8=AF=95=E6=89=A7=E8=A1=8C=EF=BC=8C?= =?UTF-8?q?=E6=8F=90=E7=A4=BA=E4=BF=A1=E6=81=AF=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../track/service/TestPlanLoadCaseService.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/backend/src/main/java/io/metersphere/track/service/TestPlanLoadCaseService.java b/backend/src/main/java/io/metersphere/track/service/TestPlanLoadCaseService.java index 8cc2ac794d..d3a2044f37 100644 --- a/backend/src/main/java/io/metersphere/track/service/TestPlanLoadCaseService.java +++ b/backend/src/main/java/io/metersphere/track/service/TestPlanLoadCaseService.java @@ -139,7 +139,13 @@ public class TestPlanLoadCaseService { try { serialRun(request); } catch (Exception e) { - MSException.throwException(e.getMessage()); + String message = e.getMessage(); + if (StringUtils.isNotEmpty(message)) { + message = message.replace("io.metersphere.commons.exception.MSException:", ""); + MSException.throwException(message); + }else{ + MSException.throwException("请求参数错误,请刷新后执行"); + } } } else { ExecutorService executorService = Executors.newFixedThreadPool(request.getRequests().size());