数据格式异常时status码设置为400,服务异常时status码设置为500,并细化服务异常业务状态码

This commit is contained in:
zhangdongxu
2018-08-03 18:08:46 +08:00
parent 4a353a3975
commit 0a10522bae
11 changed files with 498 additions and 263 deletions

View File

@@ -234,7 +234,8 @@
<bean class="com.nis.restful.DefaultRestErrorResolver">
<property name="exceptionMappingDefinitions">
<map>
<entry key="com.nis.restful.RestServiceException" value="404" />
<entry key="com.nis.restful.RestServiceException" value="400" />
<entry key="com.nis.restful.ServiceRuntimeException" value="500" />
<entry key="Throwable" value="500" />
</map>
</property>