Browse Source

update 优化启动时间

18339543638 3 years ago
parent
commit
0af6e6949c

+ 4 - 4
nb-common/log-common/src/main/java/com/nb/common/log/aop/LogAspect.java

@@ -1,6 +1,7 @@
 package com.nb.common.log.aop;
 
 import cn.dev33.satoken.stp.StpUtil;
+import cn.hutool.core.bean.BeanUtil;
 import cn.hutool.extra.spring.SpringUtil;
 import cn.hutool.http.useragent.UserAgent;
 import cn.hutool.http.useragent.UserAgentUtil;
@@ -56,11 +57,10 @@ public class LogAspect {
         Exception exception = null;
         List<Object> param = new ArrayList<>();
         try {
+
             param = Arrays.stream(point.getArgs()).filter(item -> Objects.nonNull(item) && !isFilterObject(item))
-                    .map(object->
-                            SerializationUtils.deserialize(SerializationUtils.serialize(object))
-                    ).
-                            collect(Collectors.toList());
+                    .map(BeanUtil::beanToMap)
+                    .collect(Collectors.toList());
             obj = point.proceed();
         } catch (Exception e) {
             exception = e;