Files
han-note/han-note-gateway/src/main/resources/application.yml
Hanserwei dd63d30792 feat(note): 实现笔记发布功能并优化数据模型
- 新增笔记发布接口,支持图文和视频类型
- 引入分布式ID生成器和KV存储服务
- 修改笔记、频道、话题等实体类使用LocalDateTime
- 添加频道-话题关联表及相应服务实现
- 更新数据库表结构,增加笔记内容UUID字段
- 完善笔记发布时的内容校验和异常处理
- 配置网关路由支持新的笔记服务路径
- 优化MyBatis Mapper扫描和Feign客户端配置
2025-10-08 19:37:35 +08:00

55 lines
2.0 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

server:
port: 8000 # 指定启动端口
spring:
cloud:
gateway:
routes:
- id: auth
uri: lb://han-note-auth
predicates:
- Path=/auth/**
filters:
- StripPrefix=1
- id: user
uri: lb://han-note-user
predicates:
- Path=/user/**
filters:
- StripPrefix=1
- id: note
uri: lb://han-note-note
predicates:
- Path=/note/**
filters:
- StripPrefix=1
data:
redis:
database: 5 # Redis 数据库索引(默认为 0
host: 127.0.0.1 # Redis 服务器地址
port: 6379 # Redis 服务器连接端口
password: redis # Redis 服务器连接密码(默认为空)
timeout: 5s # 读超时时间
connect-timeout: 5s # 链接超时时间
lettuce:
pool:
max-active: 200 # 连接池最大连接数
max-wait: -1ms # 连接池最大阻塞等待时间(使用负值表示没有限制)
min-idle: 0 # 连接池中的最小空闲连接
max-idle: 10 # 连接池中的最大空闲连接
sa-token:
# token 名称(同时也是 cookie 名称)
token-name: Authorization
# token前缀
token-prefix: Bearer
# token 有效期(单位:秒) 默认30天-1 代表永久有效
timeout: 2592000
# token 最低活跃频率(单位:秒),如果 token 超过此时间没有访问系统就会被冻结,默认-1 代表不限制,永不冻结
active-timeout: -1
# 是否允许同一账号多地同时登录 (为 true 时允许一起登录, 为 false 时新登录挤掉旧登录)
is-concurrent: true
# 在多人登录同一账号时,是否共用一个 token (为 true 时所有登录共用一个 token, 为 false 时每次登录新建一个 token
is-share: true
# token 风格默认可取值uuid、simple-uuid、random-32、random-64、random-128、tik
token-style: random-128
# 是否输出操作日志
is-log: true