【fix sonar】AutoLogAspect文件

This commit is contained in:
梁琦涛
2023-03-08 15:45:01 +08:00
parent eb88c3091c
commit 19c5eff30c
@@ -167,15 +167,7 @@ public class AutoLogAspect {
arguments[i] = paramsArray[i];
}
//update-begin-author:taoyan date:20200724 for:日志数据太长的直接过滤掉
PropertyFilter profilter = new PropertyFilter() {
@Override
public boolean apply(Object o, String name, Object value) {
if(value!=null && value.toString().length()>500){
return false;
}
return true;
}
};
PropertyFilter profilter = (o, name, value) -> value == null || value.toString().length() <= 500;
params = JSON.toJSONString(arguments, profilter);
//update-end-author:taoyan date:20200724 for:日志数据太长的直接过滤掉
} else {
@@ -202,7 +194,7 @@ public class AutoLogAspect {
* @return
*/
private String getOnlineLogContent(Object obj, String content){
if (Result.class.isInstance(obj)){
if (obj instanceof Result){
Result res = (Result)obj;
String msg = res.getMessage();
String tableName = res.getOnlTable();