diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/context/BusinessLogHolder.java b/kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/context/BusinessLogHolder.java similarity index 95% rename from kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/context/BusinessLogHolder.java rename to kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/context/BusinessLogHolder.java index 70c57830b..17b35cbce 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/context/BusinessLogHolder.java +++ b/kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/context/BusinessLogHolder.java @@ -1,7 +1,7 @@ -package cn.stylefeng.roses.kernel.log.business.context; +package cn.stylefeng.roses.kernel.log.api.context; import cn.hutool.core.util.ObjectUtil; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusiness; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusiness; import java.util.LinkedList; import java.util.List; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/entity/SysLogBusiness.java b/kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/pojo/entity/SysLogBusiness.java similarity index 96% rename from kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/entity/SysLogBusiness.java rename to kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/pojo/entity/SysLogBusiness.java index 8f526af1c..ecb488ca0 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/entity/SysLogBusiness.java +++ b/kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/pojo/entity/SysLogBusiness.java @@ -1,4 +1,4 @@ -package cn.stylefeng.roses.kernel.log.business.entity; +package cn.stylefeng.roses.kernel.log.api.pojo.entity; import cn.stylefeng.roses.kernel.db.api.pojo.entity.BaseEntity; import cn.stylefeng.roses.kernel.rule.annotation.ChineseDescription; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/entity/SysLogBusinessContent.java b/kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/pojo/entity/SysLogBusinessContent.java similarity index 95% rename from kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/entity/SysLogBusinessContent.java rename to kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/pojo/entity/SysLogBusinessContent.java index 2cc33d458..f4dac1912 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/entity/SysLogBusinessContent.java +++ b/kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/pojo/entity/SysLogBusinessContent.java @@ -1,4 +1,4 @@ -package cn.stylefeng.roses.kernel.log.business.entity; +package cn.stylefeng.roses.kernel.log.api.pojo.entity; import cn.stylefeng.roses.kernel.db.api.pojo.entity.BaseEntity; import cn.stylefeng.roses.kernel.rule.annotation.ChineseDescription; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/util/BusinessLogUtil.java b/kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/util/BusinessLogUtil.java similarity index 82% rename from kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/util/BusinessLogUtil.java rename to kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/util/BusinessLogUtil.java index 6c3ea76bd..67afb9dfb 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/util/BusinessLogUtil.java +++ b/kernel-d-log/log-api/src/main/java/cn/stylefeng/roses/kernel/log/api/util/BusinessLogUtil.java @@ -1,9 +1,10 @@ -package cn.stylefeng.roses.kernel.log.business.util; +package cn.stylefeng.roses.kernel.log.api.util; import cn.hutool.core.util.ObjectUtil; import cn.hutool.core.util.StrUtil; -import cn.stylefeng.roses.kernel.log.business.context.BusinessLogHolder; +import cn.stylefeng.roses.kernel.log.api.context.BusinessLogHolder; import com.alibaba.fastjson2.JSON; +import com.alibaba.fastjson2.JSONWriter; /** * 业务日志 @@ -42,7 +43,7 @@ public class BusinessLogUtil { if (param instanceof String) { stringBuffer.append(param); } else { - stringBuffer.append(JSON.toJSONString(param)); + stringBuffer.append(JSON.toJSONString(param, JSONWriter.Feature.PrettyFormat)); } } BusinessLogHolder.addContent(stringBuffer.toString()); diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/aop/BusinessLogRecordAop.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/aop/BusinessLogRecordAop.java index 7c4541914..3deaa83b6 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/aop/BusinessLogRecordAop.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/aop/BusinessLogRecordAop.java @@ -28,8 +28,8 @@ import cn.hutool.core.util.ObjectUtil; import cn.stylefeng.roses.kernel.auth.api.context.LoginContext; import cn.stylefeng.roses.kernel.auth.api.pojo.login.LoginUser; import cn.stylefeng.roses.kernel.log.api.constants.LogFileConstants; -import cn.stylefeng.roses.kernel.log.business.context.BusinessLogHolder; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusiness; +import cn.stylefeng.roses.kernel.log.api.context.BusinessLogHolder; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusiness; import cn.stylefeng.roses.kernel.log.business.service.SysLogBusinessService; import cn.stylefeng.roses.kernel.rule.annotation.BizLog; import cn.stylefeng.roses.kernel.rule.util.HttpServletUtil; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/controller/SysLogBusinessContentController.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/controller/SysLogBusinessContentController.java index fc4c1e7c2..e080ac5b8 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/controller/SysLogBusinessContentController.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/controller/SysLogBusinessContentController.java @@ -1,7 +1,7 @@ package cn.stylefeng.roses.kernel.log.business.controller; import cn.stylefeng.roses.kernel.db.api.pojo.page.PageResult; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusinessContent; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusinessContent; import cn.stylefeng.roses.kernel.log.business.pojo.request.SysLogBusinessContentRequest; import cn.stylefeng.roses.kernel.log.business.service.SysLogBusinessContentService; import cn.stylefeng.roses.kernel.rule.pojo.response.ResponseData; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/controller/SysLogBusinessController.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/controller/SysLogBusinessController.java index d05805638..a5a423aa5 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/controller/SysLogBusinessController.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/controller/SysLogBusinessController.java @@ -1,7 +1,7 @@ package cn.stylefeng.roses.kernel.log.business.controller; import cn.stylefeng.roses.kernel.db.api.pojo.page.PageResult; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusiness; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusiness; import cn.stylefeng.roses.kernel.log.business.pojo.request.SysLogBusinessRequest; import cn.stylefeng.roses.kernel.log.business.service.SysLogBusinessService; import cn.stylefeng.roses.kernel.rule.pojo.response.ResponseData; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/mapper/SysLogBusinessContentMapper.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/mapper/SysLogBusinessContentMapper.java index 3a6e916ed..6902064f0 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/mapper/SysLogBusinessContentMapper.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/mapper/SysLogBusinessContentMapper.java @@ -1,7 +1,7 @@ package cn.stylefeng.roses.kernel.log.business.mapper; import cn.stylefeng.roses.kernel.db.mp.injector.CustomBaseMapper; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusinessContent; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusinessContent; /** * 业务日志记录 Mapper 接口 diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/mapper/SysLogBusinessMapper.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/mapper/SysLogBusinessMapper.java index 0da89fd92..2ebbc6526 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/mapper/SysLogBusinessMapper.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/mapper/SysLogBusinessMapper.java @@ -1,6 +1,6 @@ package cn.stylefeng.roses.kernel.log.business.mapper; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusiness; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusiness; import com.baomidou.mybatisplus.core.mapper.BaseMapper; /** diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/SysLogBusinessContentService.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/SysLogBusinessContentService.java index a38eb067d..d9d760622 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/SysLogBusinessContentService.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/SysLogBusinessContentService.java @@ -1,7 +1,7 @@ package cn.stylefeng.roses.kernel.log.business.service; import cn.stylefeng.roses.kernel.db.api.pojo.page.PageResult; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusinessContent; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusinessContent; import cn.stylefeng.roses.kernel.log.business.pojo.request.SysLogBusinessContentRequest; import com.baomidou.mybatisplus.extension.service.IService; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/SysLogBusinessService.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/SysLogBusinessService.java index b8c843d95..f288781e2 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/SysLogBusinessService.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/SysLogBusinessService.java @@ -1,7 +1,7 @@ package cn.stylefeng.roses.kernel.log.business.service; import cn.stylefeng.roses.kernel.db.api.pojo.page.PageResult; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusiness; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusiness; import cn.stylefeng.roses.kernel.log.business.pojo.request.SysLogBusinessRequest; import com.baomidou.mybatisplus.extension.service.IService; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/impl/SysLogBusinessContentServiceImpl.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/impl/SysLogBusinessContentServiceImpl.java index cfc9a630a..23e581ff4 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/impl/SysLogBusinessContentServiceImpl.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/impl/SysLogBusinessContentServiceImpl.java @@ -5,7 +5,7 @@ import cn.stylefeng.roses.kernel.db.api.factory.PageFactory; import cn.stylefeng.roses.kernel.db.api.factory.PageResultFactory; import cn.stylefeng.roses.kernel.db.api.pojo.page.PageResult; import cn.stylefeng.roses.kernel.dsctn.api.context.DataSourceContext; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusinessContent; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusinessContent; import cn.stylefeng.roses.kernel.log.business.mapper.SysLogBusinessContentMapper; import cn.stylefeng.roses.kernel.log.business.pojo.request.SysLogBusinessContentRequest; import cn.stylefeng.roses.kernel.log.business.service.SysLogBusinessContentService; diff --git a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/impl/SysLogBusinessServiceImpl.java b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/impl/SysLogBusinessServiceImpl.java index c1e396ea3..41da9df72 100644 --- a/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/impl/SysLogBusinessServiceImpl.java +++ b/kernel-d-log/log-business/src/main/java/cn/stylefeng/roses/kernel/log/business/service/impl/SysLogBusinessServiceImpl.java @@ -5,8 +5,8 @@ import cn.hutool.core.util.ObjectUtil; import cn.stylefeng.roses.kernel.db.api.factory.PageFactory; import cn.stylefeng.roses.kernel.db.api.factory.PageResultFactory; import cn.stylefeng.roses.kernel.db.api.pojo.page.PageResult; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusiness; -import cn.stylefeng.roses.kernel.log.business.entity.SysLogBusinessContent; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusiness; +import cn.stylefeng.roses.kernel.log.api.pojo.entity.SysLogBusinessContent; import cn.stylefeng.roses.kernel.log.business.enums.SysLogBusinessExceptionEnum; import cn.stylefeng.roses.kernel.log.business.mapper.SysLogBusinessMapper; import cn.stylefeng.roses.kernel.log.business.pojo.request.SysLogBusinessRequest;