feat(ops): 添加生产监控告警基线
- 新增 Prometheus/Grafana/Loki/Promtail 监控 profile\n- 覆盖 DB、磁盘、慢 API、慢 Prisma、任务失败和小宝摘要 stale 告警\n- 补充 postgres-exporter 自定义查询、Dashboard、部署文档和校验\n\nCo-Authored-By: GPT-5 Codex <codex@openai.com>
This commit is contained in:
12
deploy/monitoring/postgres/postgres-queries.yml
Normal file
12
deploy/monitoring/postgres/postgres-queries.yml
Normal file
@@ -0,0 +1,12 @@
|
||||
ftb_xiaobao:
|
||||
query: |
|
||||
SELECT
|
||||
count(*)::float AS stale_summary_count
|
||||
FROM xiaobao_risk_summaries
|
||||
WHERE dirty = true
|
||||
OR updated_at < now() - interval '6 hours';
|
||||
metrics:
|
||||
- stale_summary_count:
|
||||
usage: GAUGE
|
||||
description: Xiaobao risk summaries that are dirty or older than 6 hours.
|
||||
|
||||
Reference in New Issue
Block a user