We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
正确结果: 原因分析: 这个错误,是apijson的bug, 调试情况, 堆栈信息,无法转化为json字符串. 建议: 屏蔽: 感觉没有太大必要,前端把这些堆栈信息打印出来 // if (error != null) { // res.put("trace:throw", error.getClass().getName()); // res.put("trace:stack", error.getStackTrace()); // }
The text was updated successfully, but these errors were encountered:
为了方便后端调试 bug。 不过既然有这个问题,可以通过新增一个
public static boolean IS_RETURN_STACK_TRACE = true;
来标记是否返回 "trace:stack"。
原先想着可以先
String traceStr = JSON.toJSONString(error.getStackTrace());
判断是否返回正常有内容的 "[...]",没有的话说明有报错,就不再返回,有就
res.put("trace:stack", JSON.parseArray(traceStr));
放进去返回,但这样做就浪费不少性能,或许没必要。
Sorry, something went wrong.
No branches or pull requests
正确结果:
原因分析:
这个错误,是apijson的bug, 调试情况, 堆栈信息,无法转化为json字符串.
建议:
屏蔽: 感觉没有太大必要,前端把这些堆栈信息打印出来
// if (error != null) {
// res.put("trace:throw", error.getClass().getName());
// res.put("trace:stack", error.getStackTrace());
// }
The text was updated successfully, but these errors were encountered: