Files
novel_dev_team_novel-plus/novel-crawl/src/main/resources/application.yml
xiongxiaoyang 938ae8571d feat(novel-crawl): 新增磁盘保护机制,支持邮件告警与自动熔断
- 实现定时检测磁盘使用率,避免爬虫耗尽磁盘资源
- 当磁盘使用率达到 85%、90%、95% 时,分别发送告警邮件
- 当使用率达到 95% 时,强制停止当前爬虫进程
2025-10-24 19:04:50 +08:00

69 lines
1.3 KiB
Java
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: 8081
servlet:
session:
timeout: 1D
spring:
profiles:
active: dev
#登录用户名密码
admin:
username: admin
password: admin
crawl:
update:
#爬虫自动更新的线程数
#建议小说数量不多或者正在运行新书入库爬虫的情况下设置为1即可
#随着小说数量的增多可以逐渐增加但建议不要超出CPU的线程数
thread: 1
# 采集间隔时间单位毫秒
interval:
min: 300
max: 500
---
#邮箱服务器
spring:
mail:
host: smtp.163.com
#发件人昵称
nickname: novel-plus
#邮箱账户
username: xxyopen@163.com
#邮箱第三方授权码
password: novel123456
#编码类型
default-encoding: UTF-8
port: 465
properties:
mail:
smtp:
auth: true
starttls:
enable: true
required: rue
socketFactory:
port: 465
class: javax.net.ssl.SSLSocketFactory
fallback: false
# 磁盘监控配置
disk-monitor:
enabled: false
interval-minutes: 5
warning-threshold: 85.0
severe-threshold: 90.0
critical-threshold: 95.0
# 告警邮件接收人列表支持多个邮箱
recipients: xxyopen@foxmail.com,12345678@qq.com