From 11b942ec7522d34c084d01d642da03a44bb9844e Mon Sep 17 00:00:00 2001 From: "Destiny.Lin" Date: Mon, 26 Aug 2024 16:17:07 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-131067=20=E8=BF=9C=E7=A8=8B=E8=AE=BE?= =?UTF-8?q?=E8=AE=A1=E5=AF=86=E7=A0=81=E6=AC=A1=E6=95=B0=E8=BF=87=E5=A4=9A?= =?UTF-8?q?=E6=8A=9B=E9=94=99=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../fr/design/env/HttpWorkspaceConnector.java | 2 +- .../boot/init/DesignWorkContextComponent.java | 20 ++++++++++--------- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/env/HttpWorkspaceConnector.java b/designer-base/src/main/java/com/fr/design/env/HttpWorkspaceConnector.java index 1c069bbb0e..e6a9720bc1 100644 --- a/designer-base/src/main/java/com/fr/design/env/HttpWorkspaceConnector.java +++ b/designer-base/src/main/java/com/fr/design/env/HttpWorkspaceConnector.java @@ -92,7 +92,7 @@ public class HttpWorkspaceConnector implements WorkspaceConnector { client.startHeartBeat(); } catch (Exception e) { client.closePool(); - throw new RemoteDesignConnectionException(e, StringUtils.EMPTY); + throw e; } CompatibleRegister.registerCompatibleEnv(); RepositoryManager.getInstance().clearLastPool(); diff --git a/designer-realize/src/main/java/com/fanruan/boot/init/DesignWorkContextComponent.java b/designer-realize/src/main/java/com/fanruan/boot/init/DesignWorkContextComponent.java index ee93d96369..51adb2fd57 100644 --- a/designer-realize/src/main/java/com/fanruan/boot/init/DesignWorkContextComponent.java +++ b/designer-realize/src/main/java/com/fanruan/boot/init/DesignWorkContextComponent.java @@ -11,6 +11,11 @@ import com.fanruan.workplace.conetxt.CompatiblePool; import com.fanruan.workplace.http.HttpConstants; import com.fanruan.workplace.http.RepositoryManager; import com.fanruan.workplace.http.WorkspaceHeartBeatShell; +import com.fr.workspace.engine.exception.RemoteDesignLoginLockHandler; +import com.fr.workspace.engine.exception.RemoteDesignNoAuthHandler; +import com.fr.workspace.engine.exception.RemoteDesignPasswordNeedUpdateHandler; +import com.fr.workspace.engine.exception.RemoteDesignPasswordStrengthHandler; +import com.fr.workspace.engine.exception.RemoteDesignUserPwdErrorHandler; import com.fanruan.workplace.http.exception.RemoteExceptionConvert; import com.fanruan.workplace.standard.ServerInfo; import com.fanruan.workplace.standard.ServerInfoOperator; @@ -43,10 +48,6 @@ import com.fr.workspace.engine.FineWorkspaceFactory; import com.fr.workspace.engine.base.FineObjectPool; import com.fr.workspace.engine.client.heartbeart.FineWorkspaceHeartbeat; import com.fr.workspace.engine.client.heartbeart.WorkspaceHeartbeat; -import com.fr.workspace.engine.exception.RemoteDesignNoAuthException; -import com.fr.workspace.engine.exception.RemoteDesignPasswordNeedUpdateException; -import com.fr.workspace.engine.exception.RemoteDesignPasswordStrengthException; -import com.fr.workspace.engine.exception.RemoteDesignUserPwdErrorException; import com.fr.workspace.engine.resource.FineWorkResource; import com.fr.workspace.engine.resource.FineWorkResourceAdaptor; import com.fr.workspace.pool.WorkRPCRegister; @@ -144,11 +145,12 @@ public class DesignWorkContextComponent { private void startErrorConvert() { - RemoteExceptionConvert.registerException(HttpConstants.USER_PWD_ERROR_CODE, new RemoteDesignUserPwdErrorException()); - RemoteExceptionConvert.registerException(HttpConstants.USER_PWD_NEED_UPDATE, new RemoteDesignPasswordNeedUpdateException()); - RemoteExceptionConvert.registerException(HttpConstants.PASSWORD_STRENGTH_ERROR_CODE, new RemoteDesignPasswordStrengthException()); - RemoteExceptionConvert.registerException(HttpConstants.REMOTE_AUTHORITY_ERROR_CODE, new RemoteDesignNoAuthException()); - RemoteExceptionConvert.registerException(HttpConstants.PASSWORD_EMPTY_ERROR_CODE, new RemoteDesignUserPwdErrorException()); + RemoteExceptionConvert.registerException(HttpConstants.USER_PWD_ERROR_CODE, new RemoteDesignUserPwdErrorHandler()); + RemoteExceptionConvert.registerException(HttpConstants.USER_PWD_NEED_UPDATE, new RemoteDesignPasswordNeedUpdateHandler()); + RemoteExceptionConvert.registerException(HttpConstants.PASSWORD_STRENGTH_ERROR_CODE, new RemoteDesignPasswordStrengthHandler()); + RemoteExceptionConvert.registerException(HttpConstants.REMOTE_AUTHORITY_ERROR_CODE, new RemoteDesignNoAuthHandler()); + RemoteExceptionConvert.registerException(HttpConstants.PASSWORD_EMPTY_ERROR_CODE, new RemoteDesignUserPwdErrorHandler()); + RemoteExceptionConvert.registerException(HttpConstants.LOGIN_LOCK, new RemoteDesignLoginLockHandler()); } private void supplementalCommon() {