使用单个指标跟踪DataDog中的成功和失败
当前,我们的代码库跟踪两个单独的指标,可以说abcsuccess
和abcfailure
。我们始终每次将指标递增1个值。
是否有必要分开这些指标?或者,我们可以通过错误的值“递增”度量标准,而1
获得成功,如果我们想要总失败计数,我们可以减去总和在总数的时间段?
我试图通过查看这两个sum:abcsuccess {*}。AS_COUNT()
and count:abcsuccess {*} as_count(as_count()。由于我总是将值增加1个,我希望这些值相同,但是
Count
值显着更高(并且始终为每次切片10的增量?)
Currently our codebase tracks two separate metrics, lets say a.b.c.success
and a.b.c.failure
. We always increment the metric by a value of 1 each time.
Is it necessary to separate these metrics? Or can we "increment" the metric by a value of 0
for errors, and 1
for success, and if we wanted a total count of failures, we could subtract the sum in a time period from total count?
I tried to confirm this could work through the metric explorer by looking at graphs for both sum:a.b.c.success{*}.as_count()
and count:a.b.c.success{*}.as_count()
. Since I'm always incrementing the value by 1, I would expect these values to be the same but the count
value is significantly higher (and always in increments of 10 per time slice?)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论