Posted in

如何聚合指标但保留关键数据:介绍自适应指标中的排除_AI阅读总结 — 包阅AI

包阅导读总结

1. 关键词:Adaptive Metrics、Exemptions、Aggregations、Critical Data、Cost Savings

2. 总结:本文介绍了 Grafana Cloud 中的 Adaptive Metrics 及其新功能 Exemptions。Adaptive Metrics 能聚合指标以降低成本,Exemptions 可保留关键数据。文中阐述了 Adaptive Metrics 的工作原理、使用中的变化及 Exemptions 的作用和类型,鼓励用户探索其增强设置。

3. 主要内容:

– Adaptive Metrics

– 能将未使用和部分使用的指标聚合,为 1200 多个组织平均降低 35%的指标成本。

– 基于使用模式不断识别聚合机会,同时尽量减少对查询的影响。

– 由聚合服务、推荐引擎等实现聚合。

– 指标使用变化

– 新的使用模式可能导致规则更新或需要修改。

– 常见请求修改原因包括发现数据新用途、开发实验功能、进行事件审查等。

– Exemptions

– 有四种类型,可保留完整指标、特定标签等。

– 让团队更好控制指标,保持关键数据完整性。

– 开始使用

– 解决数据丢失担忧,平衡控制和优化。

– 鼓励探索,提供文档,有问题可联系支持团队。

思维导图:

文章地址:https://grafana.com/blog/2024/08/22/how-to-aggregate-metrics-but-retain-critical-data-introducing-exemptions-in-adaptive-metrics/

文章来源:grafana.com

作者:Patrick Oyarzun

发布时间:2024/8/22 11:03

语言:英文

总字数:973字

预计阅读时间:4分钟

评分:83分

标签:Metrics Aggregation,Grafana Cloud,Cost Optimization,Exemptions,Data Retention


以下为原文内容

本内容来源于用户推荐转载,旨在分享知识与观点,如有侵权请联系删除 联系邮箱 media@ilingban.com

When you hear about Adaptive Metrics in Grafana Cloud, all signs point to how it’s a game changer.

Adaptive Metrics, which aggregates unused and partially used metrics into lower cardinality versions, has delivered a 35% reduction in metrics costs on average for more than 1,200 organizations.

Companies have also spoken candidly about the cost savings they gained from the feature. At Mux, “it not only saves us hundreds of thousands of dollars a year, but it’s also a forcing function for us to look closely at our metrics to find additional opportunities for time series reduction and cardinality improvements,” says Kyle Weaver, Staff Software Engineer at Mux.

And yet, you’re still hesitant about implementing automated aggregations and possibly losing critical data.

We get it. Which is why to help you with that delicate balance of maintaining optimal application performance and reducing metrics volume (all while calming that “what if” anxiety among your teams), we have enhanced Adaptive Metrics with the new Exemptions capability. Adaptive Metrics continues to provide daily recommendations for aggregating or dropping high cardinality metrics. But with Exemptions, your teams now have the ability to proactively preserve critical data by identifying and excluding certain metrics from aggregations.

In this blog, we’ll show you how Exemptions work and how they can empower you to manage your Adaptive Metrics recommendations and aggregations in Grafana Cloud.

How Adaptive Metrics works

Adaptive Metrics was developed to achieve three goals:

  1. Provide an automated way to aggregate or drop high cardinality metrics and, in turn, save users money.
  2. Continually identify opportunities to aggregate metrics based on usage patterns.
  3. Do all of the above while impacting as few queries as possible.

Put another way, Adaptive Metrics helps cut down on costs without compromising your ability to troubleshoot and diagnose issues in production.

At Grafana Labs, we have been using Adaptive Metrics for a couple of years now to reduce our internal ops metric volume by around 30-40%.

The process is straightforward: every weekday morning, an automated workflow makes a PR to our configuration repo to apply the latest recommendations. A few minutes later, that PR is merged automatically without a human review.

The aggregations are made possible by:

  1. The aggregation service: This aggregates incoming data as it is received in Grafana Cloud according to aggregation rules, ultimately lowering the amount of data that must be stored.
  2. The recommendation engine: This generates aggregation rules and automatically adapts them based on usage patterns as they change.
  3. Exemptions: This new capability allows you to fine-tune the recommendation engine by providing additional context for critical metrics that may not be reflected in your organization’s usage patterns.

How metrics aggregations adapt to your usage

When you set up Adaptive Metrics, you instantly begin aggregating and dropping low-value metrics to achieve significant savings. This is a great start!

As your usage patterns change — for example, by adding new dashboards or alerts — the recommendations engine will generate updates to your rules. In some cases, it may even recommend removing a rule altogether if, for example, the full cardinality is now being used.

However, we’ve found that this usage-based workflow is only a piece of the puzzle. As we rolled out aggregation automatically, we noticed a pattern of requests to remove or modify rules.

Here are some common reasons for these requests:

  1. Discovery of new use cases for the data: Teams might find new applications for previously discarded metrics, making them valuable again.
  2. Development of experimental features: New projects or experimental features often require comprehensive data sets that may include aggregated or dropped metrics.
  3. Incident reviews: When conducting incident reviews, teams may need detailed data to create new alerts or refine existing ones, which requires storing the full cardinality of some data going forward.

The initial workflow went like this: any engineer at Grafana Labs was empowered to open PRs against our production aggregation rules. The Adaptive Metrics team would review these PRs only to understand their use cases, then approve. Over time, we realized that what our users were really after is a way to protect the data they need regardless of how it’s being used.

How Exemptions work in Adaptive Metrics

An Exemption is a capability in Adaptive Metrics that allows you to identify critical metrics that should be preserved, and therefore excluded, from the recommendations engine. This will provide your teams more control over your metrics and help maintain the integrity of your important data.

There are four types of Exemptions in Adaptive Metrics:

  1. Keep a whole metric intact: Ensure that certain metrics remain untouched by aggregation, preserving their complete data set.
  2. Preserve a specific label across all metrics: Maintain a particular label in all metrics to ensure consistent data categorization.
  3. Retain a label on a particular metric: Keep a specific label on a specific metric, maintaining detailed tracking for important metrics.
  4. Disable recommendations entirely for a specific metric: Prevent any recommendations from being applied to a particular metric, ensuring its aggregation remains in place.

By leveraging these Exemptions, you can customize how Adaptive Metrics handles your data, ensuring that essential information is always available while enjoying the benefits of reduced cardinality and costs.

Get started with Exemptions in Adaptive Metrics

Exemptions in Adaptive Metrics address the concern of data loss by providing you with the tools to retain critical data while benefiting from cost optimization. With Exemptions, you can effectively balance control and optimization, ensuring that your metrics remain accurate and useful.

We encourage you to explore how Exemptions can enhance your Adaptive Metrics setup. To get started, check out our detailed Adaptive Metrics documentation. If you have any questions or need further assistance, don’t hesitate to contact our support team.

Grafana Cloud is the easiest way to get started with metrics, logs, traces, dashboards, and more. We have a generous forever-free tier and plans for every use case. Sign up for free now!