feat(security): 重构安全配置并添加用户认证功能
refactor: 将ResponseMessage移动到config包并增强功能 feat: 添加用户管理相关功能及密码加密配置 fix: 修复HelpController中README文件路径问题 docs: 更新application.properties配置注释 style: 清理无用导入和日志文件
This commit is contained in:
@@ -23,6 +23,7 @@ spring.jpa.show-sql=false
|
||||
spring.jpa.properties.hibernate.format_sql=true
|
||||
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL8Dialect
|
||||
spring.jpa.open-in-view=false
|
||||
|
||||
# JPA性能优化配置
|
||||
spring.jpa.properties.hibernate.jdbc.batch_size=30
|
||||
spring.jpa.properties.hibernate.order_inserts=true
|
||||
@@ -31,20 +32,20 @@ spring.jpa.properties.hibernate.order_updates=true
|
||||
# spring.jpa.properties.hibernate.cache.use_second_level_cache=true
|
||||
# spring.jpa.properties.hibernate.cache.use_query_cache=true
|
||||
|
||||
缓存配置
|
||||
# 缓存配置
|
||||
spring.cache.type=redis
|
||||
spring.cache.redis.time-to-live=1800000
|
||||
spring.cache.redis.key-prefix=CACHE_
|
||||
spring.cache.redis.use-key-prefix=true
|
||||
spring.cache.redis.cache-null-values=false
|
||||
|
||||
Redis配置
|
||||
# Redis配置
|
||||
spring.redis.host=localhost
|
||||
spring.redis.port=6379
|
||||
spring.redis.password=123456
|
||||
spring.redis.database=0
|
||||
spring.redis.timeout=10000ms
|
||||
Redis连接池优化配置
|
||||
# Redis连接池优化配置
|
||||
spring.redis.lettuce.pool.max-active=8
|
||||
spring.redis.lettuce.pool.max-wait=10000ms
|
||||
spring.redis.lettuce.pool.max-idle=8
|
||||
@@ -76,13 +77,6 @@ jwt.token-prefix=Bearer
|
||||
cors.allowed-origins=http://localhost:3000
|
||||
cors.allowed-methods=GET,POST,PUT,DELETE,OPTIONS
|
||||
cors.allowed-headers=*,
|
||||
Content-Type,
|
||||
X-Requested-With,
|
||||
accept,
|
||||
Origin,
|
||||
Access-Control-Request-Method,
|
||||
Access-Control-Request-Headers,
|
||||
Authorization
|
||||
cors.allow-credentials=true
|
||||
cors.max-age=3600
|
||||
|
||||
@@ -101,10 +95,10 @@ server.servlet.session.timeout=30m
|
||||
server.session.tracking-modes=cookie
|
||||
|
||||
# 国际化配置
|
||||
#spring.mvc.locale-resolver=fixed
|
||||
#spring.mvc.locale=zh_CN
|
||||
spring.mvc.locale-resolver=fixed
|
||||
spring.web.locale=zh_CN
|
||||
#
|
||||
## 响应编码配置
|
||||
#spring.http.encoding.charset=UTF-8
|
||||
#spring.http.encoding.enabled=true
|
||||
#spring.http.encoding.force=true
|
||||
spring.http.encoding.charset=UTF-8
|
||||
spring.http.encoding.enabled=true
|
||||
spring.http.encoding.force=true
|
||||
|
||||
Reference in New Issue
Block a user