Commit 324c7e8c authored by liaozan's avatar liaozan 🏀

Add test env

parent 4b934707
......@@ -734,6 +734,14 @@
<docker.registry>registry-vpc.cn-hangzhou.aliyuncs.com/schbrain_dev</docker.registry>
</properties>
</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>
<id>prod</id>
......
......@@ -29,16 +29,15 @@ public class DubboExceptionFilter extends ExceptionFilter {
return;
}
Throwable cause = ExceptionUtil.getRootCause(appResponse.getException());
if (cause instanceof ConstraintViolationException) {
cause = createParamInvalidException(invocation, (ConstraintViolationException) cause);
Throwable rootCause = ExceptionUtil.getRootCause(appResponse.getException());
if (rootCause instanceof ConstraintViolationException) {
rootCause = createParamInvalidException(invocation, (ConstraintViolationException) rootCause);
}
appResponse.setException(rootCause);
appResponse.setException(cause);
logErrorDetail(invocation, cause);
logErrorDetail(invocation, rootCause);
if (cause instanceof BaseException) {
if (rootCause instanceof BaseException) {
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