Commit 324c7e8c authored by liaozan's avatar liaozan 🏀

Add test env

parent 4b934707
...@@ -734,6 +734,14 @@ ...@@ -734,6 +734,14 @@
<docker.registry>registry-vpc.cn-hangzhou.aliyuncs.com/schbrain_dev</docker.registry> <docker.registry>registry-vpc.cn-hangzhou.aliyuncs.com/schbrain_dev</docker.registry>
</properties> </properties>
</profile> </profile>
<!-- 测试环境 -->
<profile>
<id>test</id>
<properties>
<spring.profile>test</spring.profile>
<docker.registry>registry-vpc.cn-hangzhou.aliyuncs.com/schbrain_dev</docker.registry>
</properties>
</profile>
<!-- 生产环境 --> <!-- 生产环境 -->
<profile> <profile>
<id>prod</id> <id>prod</id>
......
...@@ -29,16 +29,15 @@ public class DubboExceptionFilter extends ExceptionFilter { ...@@ -29,16 +29,15 @@ public class DubboExceptionFilter extends ExceptionFilter {
return; return;
} }
Throwable cause = ExceptionUtil.getRootCause(appResponse.getException()); Throwable rootCause = ExceptionUtil.getRootCause(appResponse.getException());
if (rootCause instanceof ConstraintViolationException) {
if (cause instanceof ConstraintViolationException) { rootCause = createParamInvalidException(invocation, (ConstraintViolationException) rootCause);
cause = createParamInvalidException(invocation, (ConstraintViolationException) cause);
} }
appResponse.setException(rootCause);
appResponse.setException(cause); logErrorDetail(invocation, rootCause);
logErrorDetail(invocation, cause);
if (cause instanceof BaseException) { if (rootCause instanceof BaseException) {
return; return;
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment