From 342481d86c7fa907d803bf110d86bac2c136ec7a Mon Sep 17 00:00:00 2001 From: zxc <954985706@qq.com> Date: Wed, 10 Jun 2020 10:53:10 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E7=AB=A0=E5=AE=A1=E6=A0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/commons/tools/utils/HttpClientManager.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/HttpClientManager.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/HttpClientManager.java index 439997d264..adbbbf8f9a 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/HttpClientManager.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/HttpClientManager.java @@ -157,7 +157,7 @@ public class HttpClientManager { } } catch (Exception e) { log.error("execute exception", e); - new RenException(EpmetErrorCode.SERVER_ERROR.getCode(), EpmetErrorCode.SERVER_ERROR.getMsg()); + return new Result().error(EpmetErrorCode.SERVER_ERROR.getCode(), e.getMessage()); } finally { httpMethod.releaseConnection(); try { @@ -167,7 +167,7 @@ public class HttpClientManager { } catch (IOException e) { } } - throw new RenException(EpmetErrorCode.SERVER_ERROR.getCode(), EpmetErrorCode.SERVER_ERROR.getMsg()); + return new Result().error(EpmetErrorCode.SERVER_ERROR.getCode(), EpmetErrorCode.SERVER_ERROR.getMsg()); } public static void main(String[] args) {