From 7c2cf7e5701857993b1261c54d7edb7669b92f3c Mon Sep 17 00:00:00 2001 From: wenc000 <450292408@qq.com> Date: Wed, 12 Aug 2020 16:42:51 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=B8=8D=E6=8D=95=E8=8E=B7?= =?UTF-8?q?=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../control/client/socket/aspect/ClientExceptionAspect.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cloud-central-control-client/src/main/java/com/cm/central/control/client/socket/aspect/ClientExceptionAspect.java b/cloud-central-control-client/src/main/java/com/cm/central/control/client/socket/aspect/ClientExceptionAspect.java index ea81982..e77f1c0 100644 --- a/cloud-central-control-client/src/main/java/com/cm/central/control/client/socket/aspect/ClientExceptionAspect.java +++ b/cloud-central-control-client/src/main/java/com/cm/central/control/client/socket/aspect/ClientExceptionAspect.java @@ -8,6 +8,8 @@ import org.aspectj.lang.annotation.Aspect; import org.aspectj.lang.annotation.Pointcut; import org.springframework.core.annotation.Order; import org.springframework.security.core.AuthenticationException; +import org.springframework.security.oauth2.common.exceptions.OAuth2Exception; +import org.springframework.security.oauth2.provider.ClientRegistrationException; import org.springframework.stereotype.Component; import javax.annotation.Resource; @@ -41,7 +43,9 @@ public class ClientExceptionAspect { result = proceedingJoinPoint.proceed(); } catch (Throwable e) { boolean exceptionFlag = e instanceof SystemException - || e instanceof AuthenticationException; + || e instanceof AuthenticationException + || e instanceof OAuth2Exception + || e instanceof ClientRegistrationException; if (!exceptionFlag) { new Thread(() -> { exceptionServiceImpl.writeThrowable(e);