故障定位方法
当添加新RSS源出现抓取异常时,建议按以下流程排查:
- Basic validation:使用在线RSS验证器(如W3C Feed Validation Service)检查源格式
- log analysis:查看Github Action的cron-job日志(.github/workflows目录)
Systematic solutions
- 代理配置:对于被墙的海外源,在cron_job.yml中添加proxy配置项
- fault tolerance mechanism:修改src/scraper.js加入重试逻辑(建议3次重试+指数退避)
- 解析优化:针对特殊格式:
- 动态网页使用Puppeteer渲染(需调整Docker配置)
- JSON格式源改用axios库请求
Preventive maintenance
建议建立RSS源健康检查系统:
- 在Firestore创建feed_status集合记录抓取成功率
- 设置Discord Webhook告警(参考项目alert-system分支)
- 对不稳定源启用Readability API二次解析
This answer comes from the articleAudibit: turning popular tech articles into ready-to-listen audio podcastsThe