Skip to content
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

HTTPJSONCollector 'double-dots' Hystrix metrics? #523

Open
mejofi opened this issue Aug 23, 2016 · 2 comments
Open

HTTPJSONCollector 'double-dots' Hystrix metrics? #523

mejofi opened this issue Aug 23, 2016 · 2 comments

Comments

@mejofi
Copy link

mejofi commented Aug 23, 2016

Apologies if this is a configuration option I have missed, but I am having an issue with the HTTPJSONCollector talking to a Hystrix metrics endpoint in a Java application. It collects everything just fine, but inserts an extra dot in the collected data, regardless of whether we set the path, or how long this path is in terms of elements.

No other configuration other than enabled and url, which yields entries like this;

servers.net.example.appserv.httpjson..hystrix.ThreadPool.x.x 0 1471943878

The Hystrix endpoint is the default configuration, as far as I know. Is this expected behaviour, an error in the data, or some mismatch between collector and endpoint?

JSON data is formatted like this;

{"hystrix.ThreadPool.x.x":0,"hystrix.Command.x.x":0}

Much more extensive than that, but the above is the basic format; all on one line, key-value pairs separated by commas, curly braces, validates as proper JSON.

Thanks!

@josegonzalez
Copy link
Member

Seems like a prefixing bug. I feel as though there was a pr made recently to fix this, though I'll have to check.

@shortdudey123
Copy link
Member

This is due to the _json_to_flat_metrics method having prefix empty on the initial call. This causes a leading dot to be added on line 49 (probably same thing with line 41).

I do not have time to put a PR in right now so feel free to submit one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants