普罗米修斯的使用 scrape_timeout

Use of Prometheus scrape_timeout

在 prometheus 配置中,我有一份符合这些规范的工作:

- job_name: name_of_my_job
     scrape_interval: 5m
     scrape_timeout: 30s
     metrics_path: /metrics
     scheme: http

创建指标的脚本需要 3 分钟才能完成,但在 prometheus 中我看不到指标。 scrape_timeout变量的操作是什么?

每 5 分钟 (scrape_interval) Prometheus 将从给定的 URL 获取指标。它将尝试 30 秒 (scrape_timeout) 来获取指标,如果在这段时间内无法 抓取 ,它将超时。