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

Add support for labels #53

Open
fabMrc opened this issue Feb 2, 2017 · 1 comment
Open

Add support for labels #53

fabMrc opened this issue Feb 2, 2017 · 1 comment

Comments

@fabMrc
Copy link

fabMrc commented Feb 2, 2017

Hi

Like other reporters, it will be nice to add the labels support for each metrics types. It allows drilldown and aggregation over dimensions. Traditionnally hostname/instanceId/port are some common labels.
For exemple :

{
  "name": "usa-gov-heartbearts",
  "@timestamp": "2013-07-20T09:29:58.000+0000",
  "count": 18
  "tags":
    {
        "hostname": "server1",
        "service_id": "myapplication_id",
        "port": 8087,
        "other_label": 1.0
    }
}

And the API

ElasticSearchReporter reporter= ElasticSearchReporter .forRegistry(metrics). .withTags(ImmutableMap.of("other", "tags")).prefix(prefix).build()
@vyaghini
Copy link

+1 this. Otherwise you end up adding everything to the metric name and then have to parse it and extract all the info.

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

No branches or pull requests

2 participants