prometheus v2.52.0 版本更新介绍
发布日期: 2024-05-08
版本号: v2.52.0
Prometheus最新版本更新包含功能新增、性能优化及问题修复。新增功能包括:Kubernetes服务发现模块添加追踪API请求失败的指标,支持端点切片角色中注入节点与区域元数据标签;Azure服务发现与远程写入支持使用官方授权SDK;告警模块支持原生直方图模板;Linode服务发现新增IPv6范围探测与区域过滤。性能优化方面,PromQL提升正则匹配查询与聚合运算效率,TSDB模块改进数据块压缩策略(优先处理内存占用较高的头部数据),并优化多项底层性能。可观测性增强包括统一日志中删除序列的计数字段、记录WAL重放期间的分块加载耗时、完善信号终止处理日志等。问题修复涵盖PromQL直方图统计偏差、标签重复、负值桶标准差计算错误,修复抓取模块直方图模式配置异常、TSDB空头压缩计数错误、远程读取内存泄漏、API请求取消响应未终止等缺陷,同时修复promtool工具在无直方图数据时的崩溃问题。
更新内容 (中文)
- [变更] TSDB:修复对超出保留周期数据块的谓词检查,使其包含恰好位于保留边界的数据块。#9633
- [功能] Kubernetes服务发现:新增
prometheus_sd_kubernetes_failures_total
指标用于追踪Kubernetes API请求失败次数。#13554 - [功能] Kubernetes服务发现:在使用endpointslice角色时添加节点(node)和区域(zone)元数据标签。#13935
- [功能] Azure服务发现/远程写入:支持使用Azure授权SDK。#13099
- [功能] 告警:支持原生直方图模板化。#13731
- [功能] Linode服务发现:支持IPv6范围发现和区域过滤。#13774
- [优化] PromQL:提升带正则表达式匹配器的查询性能。#13461
- [优化] PromQL:提升聚合运算符使用时的性能。#13744
- [优化] PromQL:验证label_join的目标标签。#13803
- [优化] 抓取:单次抓取期间出现重复序列时递增
prometheus_target_scrapes_sample_duplicate_timestamp_total
指标。#12933 - [优化] TSDB:多项性能改进。#13742 #13673 #13782
- [优化] TSDB:当需要压缩head时暂停常规块压缩(优先处理head以降低内存消耗)。#13754
- [优化] 可观测性:改进信号处理终止时的日志记录。#13772
- [优化] 可观测性:所有删除序列的日志行统一使用"num_dropped"键。#13823
- [优化] 可观测性:在WAL回放期间记录chunk快照和mmaped chunk回放耗时。#13838
- [优化] 可观测性:记录是否从WBL创建块进行压缩。#13846
- [修复] PromQL:修复查询直方图时样本数量统计不准确的问题。#13667
- [修复] PromQL:修复当直方图包含负桶时的
histogram_stddev
和histogram_stdvar
计算。#13852 - [修复] PromQL:修复特定查询中可能出现的指标结果标签名和值重复问题。#13845
- [修复] 抓取:修复抓取时原生直方图schema因子设置问题。#13846
- [修复] TSDB:修复创建WAL检查点统计时直方图样本计数问题。#13776
- [修复] TSDB:修复压缩空head的情况。#13755
- [修复] TSDB:在WAL检查点中统计浮点直方图。#13844
- [修复] 远程读取:修复因请求中断导致的内存泄漏问题。#13777
- [修复] API:当
/api/v1/series/
请求被取消时停止构建响应。#13766 - [修复] promtool:修复
promtool tsdb analyze --extended
在没有原生直方图时panic的问题。#13976
更新内容 (原始)
- [CHANGE] TSDB: Fix the predicate checking for blocks which are beyond the retention period to include the ones right at the retention boundary. #9633
- [FEATURE] Kubernetes SD: Add a new metric
prometheus_sd_kubernetes_failures_total
to track failed requests to Kubernetes API. #13554 - [FEATURE] Kubernetes SD: Add node and zone metadata labels when using the endpointslice role. #13935
- [FEATURE] Azure SD/Remote Write: Allow usage of Azure authorization SDK. #13099
- [FEATURE] Alerting: Support native histogram templating. #13731
- [FEATURE] Linode SD: Support IPv6 range discovery and region filtering. #13774
- [ENHANCEMENT] PromQL: Performance improvements for queries with regex matchers. #13461
- [ENHANCEMENT] PromQL: Performance improvements when using aggregation operators. #13744
- [ENHANCEMENT] PromQL: Validate label_join destination label. #13803
- [ENHANCEMENT] Scrape: Increment
prometheus_target_scrapes_sample_duplicate_timestamp_total
metric on duplicated series during one scrape. #12933 - [ENHANCEMENT] TSDB: Many improvements in performance. #13742 #13673 #13782
- [ENHANCEMENT] TSDB: Pause regular block compactions if the head needs to be compacted (prioritize head as it increases memory consumption). #13754
- [ENHANCEMENT] Observability: Improved logging during signal handling termination. #13772
- [ENHANCEMENT] Observability: All log lines for drop series use “num_dropped” key consistently. #13823
- [ENHANCEMENT] Observability: Log chunk snapshot and mmaped chunk replay duration during WAL replay. #13838
- [ENHANCEMENT] Observability: Log if the block is being created from WBL during compaction. #13846
- [BUGFIX] PromQL: Fix inaccurate sample number statistic when querying histograms. #13667
- [BUGFIX] PromQL: Fix
histogram_stddev
andhistogram_stdvar
for cases where the histogram has negative buckets. #13852 - [BUGFIX] PromQL: Fix possible duplicated label name and values in a metric result for specific queries. #13845
- [BUGFIX] Scrape: Fix setting native histogram schema factor during scrape. #13846
- [BUGFIX] TSDB: Fix counting of histogram samples when creating WAL checkpoint stats. #13776
- [BUGFIX] TSDB: Fix cases of compacting empty heads. #13755
- [BUGFIX] TSDB: Count float histograms in WAL checkpoint. #13844
- [BUGFIX] Remote Read: Fix memory leak due to broken requests. #13777
- [BUGFIX] API: Stop building response for
/api/v1/series/
when the API request was cancelled. #13766 - [BUGFIX] promtool: Fix panic on
promtool tsdb analyze --extended
when no native histograms are present. #13976
下载链接
- prometheus-2.52.0.darwin-amd64.tar.gz
- prometheus-2.52.0.darwin-arm64.tar.gz
- prometheus-2.52.0.dragonfly-amd64.tar.gz
- prometheus-2.52.0.freebsd-386.tar.gz
- prometheus-2.52.0.freebsd-amd64.tar.gz
- prometheus-2.52.0.freebsd-arm64.tar.gz
- prometheus-2.52.0.freebsd-armv6.tar.gz
- prometheus-2.52.0.freebsd-armv7.tar.gz
- prometheus-2.52.0.illumos-amd64.tar.gz
- prometheus-2.52.0.linux-386.tar.gz
- prometheus-2.52.0.linux-amd64.tar.gz
- prometheus-2.52.0.linux-arm64.tar.gz
- prometheus-2.52.0.linux-armv5.tar.gz
- prometheus-2.52.0.linux-armv6.tar.gz
- prometheus-2.52.0.linux-armv7.tar.gz
- prometheus-2.52.0.linux-mips.tar.gz
- prometheus-2.52.0.linux-mips64.tar.gz
- prometheus-2.52.0.linux-mips64le.tar.gz
- prometheus-2.52.0.linux-mipsle.tar.gz
- prometheus-2.52.0.linux-ppc64.tar.gz
- prometheus-2.52.0.linux-ppc64le.tar.gz
- prometheus-2.52.0.linux-riscv64.tar.gz
- prometheus-2.52.0.linux-s390x.tar.gz
- prometheus-2.52.0.netbsd-386.tar.gz
- prometheus-2.52.0.netbsd-amd64.tar.gz
- prometheus-2.52.0.netbsd-arm64.tar.gz
- prometheus-2.52.0.netbsd-armv6.tar.gz
- prometheus-2.52.0.netbsd-armv7.tar.gz
- prometheus-2.52.0.windows-386.tar.gz
- prometheus-2.52.0.windows-386.zip
- prometheus-2.52.0.windows-amd64.tar.gz
- prometheus-2.52.0.windows-amd64.zip
- prometheus-2.52.0.windows-arm64.tar.gz
- prometheus-2.52.0.windows-arm64.zip
- prometheus-web-ui-2.52.0.tar.gz
- sha256sums.txt