2024年3月29日

prometheus类型

摘要: Counter:只增。 # 查找过去1分钟增长量 sum(increase(prometheus_http_request_count{}[1m])) Gauge:可增可减。 # 查找瞬时值 sum(prometheus_http_request_gauge{}) Histograms:样本落在桶中 阅读全文

posted @ 2024-03-29 19:58 王景迁 阅读(38) 评论(0) 推荐(0)

prometheus自定义注册表

摘要: // 在自定义注册表中只有需要的变量,没有默认的Go运行时指标和prometheus指标 registry := prometheus.NewRegistry() test:= prometheus.NewCounter(prometheus.CounterOpts{ Name: "test", H 阅读全文

posted @ 2024-03-29 19:44 王景迁 阅读(37) 评论(0) 推荐(0)

导航