Commit 32e49fa4 authored by Java—KA—李 青's avatar Java—KA—李 青

增加错误日志信息

parent c7086717
...@@ -56,7 +56,7 @@ public class ExceptionHandlingController implements IBaseController { ...@@ -56,7 +56,7 @@ public class ExceptionHandlingController implements IBaseController {
HttpServletRequest request = getRequest(); HttpServletRequest request = getRequest();
String uri = request.getRequestURI(); String uri = request.getRequestURI();
String registerFrom = request.getParameter("registerFrom"); String registerFrom = request.getParameter("registerFrom");
LOGGER.error("接口异常 URI:{}, registerFrom:{}", uri, registerFrom, e); LOGGER.error("[exception][global_exception]接口异常 URI:{}, registerFrom:{}", uri, registerFrom, e);
return EXCEPTION_RESULT; return EXCEPTION_RESULT;
} }
} }
...@@ -15,6 +15,7 @@ import cn.quantgroup.xyqb.service.wechat.IWechatService; ...@@ -15,6 +15,7 @@ import cn.quantgroup.xyqb.service.wechat.IWechatService;
import cn.quantgroup.xyqb.util.IPUtil; import cn.quantgroup.xyqb.util.IPUtil;
import cn.quantgroup.xyqb.util.MqUtils; import cn.quantgroup.xyqb.util.MqUtils;
import cn.quantgroup.xyqb.util.ValidationUtil; import cn.quantgroup.xyqb.util.ValidationUtil;
import cn.quantgroup.xyqb.util.encrypt.MD5Util;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.alibaba.fastjson.TypeReference; import com.alibaba.fastjson.TypeReference;
...@@ -320,10 +321,12 @@ public class InnerController implements IBaseController { ...@@ -320,10 +321,12 @@ public class InnerController implements IBaseController {
@LogHttpCaller @LogHttpCaller
public JsonResult findUserFullInfoByPhone(String phoneNo) { public JsonResult findUserFullInfoByPhone(String phoneNo) {
if (StringUtils.isBlank(phoneNo)) { if (StringUtils.isBlank(phoneNo)) {
LOGGER.warn("[findUserFullInfoByPhone]phoneNo为空");
return JsonResult.buildErrorStateResult(null, null); return JsonResult.buildErrorStateResult(null, null);
} }
Optional<UserFullInfo> userFullInfoOptional = userApiService.getUserFullInfoByPhone(phoneNo); Optional<UserFullInfo> userFullInfoOptional = userApiService.getUserFullInfoByPhone(phoneNo);
if (!userFullInfoOptional.isPresent()) { if (!userFullInfoOptional.isPresent()) {
LOGGER.warn("[findUserFullInfoByPhone]没有用户信息,phoneNo={}", MD5Util.build(phoneNo));
return JsonResult.buildErrorStateResult(null, null); return JsonResult.buildErrorStateResult(null, null);
} }
return JsonResult.buildSuccessResult(null, userFullInfoOptional.get()); return JsonResult.buildSuccessResult(null, userFullInfoOptional.get());
...@@ -338,10 +341,12 @@ public class InnerController implements IBaseController { ...@@ -338,10 +341,12 @@ public class InnerController implements IBaseController {
@LogHttpCaller @LogHttpCaller
public JsonResult findUserFullInfoByUUuid(String uuid) { public JsonResult findUserFullInfoByUUuid(String uuid) {
if (StringUtils.isBlank(uuid)) { if (StringUtils.isBlank(uuid)) {
LOGGER.warn("[findUserFullInfoByPhone]uuid为空");
return JsonResult.buildErrorStateResult(null, null); return JsonResult.buildErrorStateResult(null, null);
} }
Optional<UserFullInfo> userFullInfoOptional = userApiService.getUserFullInfoByUuid(uuid); Optional<UserFullInfo> userFullInfoOptional = userApiService.getUserFullInfoByUuid(uuid);
if (!userFullInfoOptional.isPresent()) { if (!userFullInfoOptional.isPresent()) {
LOGGER.warn("[findUserFullInfoByUUuid]没有用户信息,uuid={}", uuid);
return JsonResult.buildErrorStateResult(null, null); return JsonResult.buildErrorStateResult(null, null);
} }
return JsonResult.buildSuccessResult(null, userFullInfoOptional.get()); return JsonResult.buildSuccessResult(null, userFullInfoOptional.get());
......
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