New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
xds: improve how envoy metrics are emitted #6312
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
One bikeshed on label name but not a big deal.
It would be awesome if you have this running locally if you could paste some sample metrics from the prometheus output so we can get a feel for the way the labelling comes out (I looked at the grafana dash so I have a good idea but would be nice to see the real thing as a sanity check).
Also, did you look at what happens to statsd metrics with this config? I'm not super clear on that but maybe could use the existing statsd integration test and make it fail and dump the raw statsd metrics sent or something?
Since generated envoy clusters all are named using (mostly) SNI syntax we can have envoy read the various fields out of that structure and emit it as stats labels to the various telemetry backends. I changed the delimiter for the 'customization hash' from ':' to '~' because ':' is always reencoded by envoy as '_' when generating metrics keys.
431bd8c
to
55e58da
Compare
I scraped the https://gist.github.com/rboyer/9b880e0fb29c5f2f215741bb9fddc707 The stats extraction, understandably, does nothing to the plain statsd output because there's no place in the protocol IIRC to send tags. The dogstatsd one however does what you'd expect. |
I assume it's intentional that 👍 Thanks RB this looks great to me. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me. I just have the one question about some regexes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Since generated envoy clusters all are named using (mostly) SNI syntax
we can have envoy read the various fields out of that structure and emit
it as stats labels to the various telemetry backends.
I changed the delimiter for the 'customization hash' from ':' to '~'
because ':' is always reencoded by envoy as '_' when generating metrics
keys.
Fixes #6227
An updated grafana/prometheus dashboard for connect is available here: https://gist.github.com/rboyer/f8a3a35feec3a27010192bda5796769e