mirror of
https://gitee.com/wangkang/udf.git
synced 2026-10-29 16:55:10 +00:00
更新
This commit is contained in:
+4
-2
@@ -30,13 +30,15 @@ public class ExceptionHandle extends ResponseEntityExceptionHandler {
|
||||
httpStatus = objectResponseEntity.getStatusCode();
|
||||
headers = objectResponseEntity.getHeaders();
|
||||
body = objectResponseEntity.getBody();
|
||||
} finally {
|
||||
return this.handleExceptionInternal(e, body, headers, httpStatus, req);
|
||||
} catch (Exception ex) {
|
||||
log.warn("非系统异常,转入自定义异常处理逻辑:{}", e.getMessage());
|
||||
}
|
||||
return this.handleExceptionInternal(e, body, headers, httpStatus, req);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected ResponseEntity<Object> handleExceptionInternal(Exception ex, Object body, HttpHeaders headers, HttpStatus status, WebRequest request) {
|
||||
log.error("错误日志:", ex);
|
||||
return super.handleExceptionInternal(ex, body, headers, status, request);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user