[Asterisk-code-review] res_statsd: replace meter type with counter (asterisk[16])
Rijnhard Hessel
asteriskteam at digium.com
Thu Jul 8 05:09:04 CDT 2021
Attention is currently required from: Joshua Colp.
Rijnhard Hessel has posted comments on this change. ( https://gerrit.asterisk.org/c/asterisk/+/16149 )
Change subject: res_statsd: replace meter type with counter
......................................................................
Patch Set 2:
(2 comments)
File include/asterisk/statsd.h:
https://gerrit.asterisk.org/c/asterisk/+/16149/comment/82c6ebbc_4dc99754
PS1, Line 44: /*! Events over time. Sorta like increment-only counters. */
> This is a publicly defined API. […]
"Metric types are non-standard and poorly supported by StatsD servers"
would you like this in the code?
File res/res_chan_stats.c:
https://gerrit.asterisk.org/c/asterisk/+/16149/comment/3edd335f_b6c7e5da
PS1, Line 76: ast_statsd_log(ast_str_buffer(metric), AST_STATSD_COUNTER, 1);
> What impact does this have to any potential existing users?
it depends on the statsd server involved, which makes it complicated.
The safest is to assume that it is a breaking change.
And the safest would actually be to change the metric name, to avoid one key being used for two different types (which is usually where things become a problem), so what I can do is just suffix these stats with "_meter" to avoid that.
this would also make it somewhat safe for BC, the only catch is any server that did actually support the metric type will suddenly have a stat that doesn't work anymore, but the change will be trivial.
--
To view, visit https://gerrit.asterisk.org/c/asterisk/+/16149
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-Change-Id: I5fcb385983a1b88f03696ff30a26b55c546a1dd7
Gerrit-Change-Number: 16149
Gerrit-PatchSet: 2
Gerrit-Owner: Rijnhard Hessel <rijnhard at teleforge.co.za>
Gerrit-Reviewer: Friendly Automation
Gerrit-Reviewer: Joshua Colp <jcolp at sangoma.com>
Gerrit-Attention: Joshua Colp <jcolp at sangoma.com>
Gerrit-Comment-Date: Thu, 08 Jul 2021 10:09:04 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Joshua Colp <jcolp at sangoma.com>
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20210708/9a359488/attachment.html>
More information about the asterisk-code-review
mailing list