feat(log): 新增日志注解功能并集成到认证流程

- 新增 @Log 注解及其配置类 LogConfig
- 在 AuthController 的 refreshToken 方法上添加 @Log 注解
- 创建 zkh-log 模块并引入 spring-boot-starter-aop 依赖
- 在 zkh-web 模块中引入 zkh-log 依赖
- 调整 GlobalExceptionHandler 和 RedisConfig 类中的代码缩进格式
- 更新 pom.xml 文件,加入 zkh-log 模块并调整依赖版本声明位置
- 修改 SpringDocConfig、WebSecurityConfig 等配置类的 bean 名称以避免冲突
This commit is contained in:
zkh
2025-12-01 16:31:45 +08:00
parent a7e1c26853
commit fe2240e266
11 changed files with 317 additions and 271 deletions

23
zkh-log/pom.xml Normal file
View File

@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>vip.jcfd</groupId>
<artifactId>zkh-framework</artifactId>
<version>1.4</version>
</parent>
<artifactId>zkh-log</artifactId>
<name>ZKH log</name>
<description>Logging utilities for ZKH framework</description>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-aop</artifactId>
</dependency>
</dependencies>
</project>

View File

@ -0,0 +1,10 @@
package vip.jcfd.log.annotation;
import java.lang.annotation.*;
@Documented
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.METHOD)
public @interface Log {
String value();
}

View File

@ -0,0 +1,7 @@
package vip.jcfd.log.annotation.config;
import org.springframework.context.annotation.Configuration;
@Configuration("_logConfiguration")
public class LogConfig {
}