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

Replica labels shouldn't be added to exemplar labels #4222

Closed
yeya24 opened this issue May 11, 2021 · 0 comments · Fixed by #4223
Closed

Replica labels shouldn't be added to exemplar labels #4222

yeya24 opened this issue May 11, 2021 · 0 comments · Fixed by #4223

Comments

@yeya24
Copy link
Contributor

yeya24 commented May 11, 2021

Thanos, Prometheus and Golang version used:

Latest

What happened:

While working on #4221, I found for exemplar APIs, replica labels are added to both series labels and exemplar labels.

For example, one example response is:

curl 'localhost:49463/api/v1/query_exemplars?end=1620780122.472&query=http_request_duration_seconds_bucket%7Bhandler%3D%22label_names%22%7D&start=1620772922.472' | jq .

{
  "status": "success",
  "data": [
    {
      "seriesLabels": {
        "__name__": "http_request_duration_seconds_bucket",
        "code": "200",
        "handler": "label_names",
        "instance": "e2e_test_exemplars_fanout-querier-query:8080",
        "job": "myself",
        "le": "0.01",
        "method": "get",
        "prometheus": "ha"
      },
      "exemplars": [
        {
          "labels": {
            "prometheus": "ha",
            "traceID": "69ab3ca4a0b7f639"
          },
          "timestamp": 1620776522.474,
          "value": "0.001569066"
        }
      ]
    }
  ]
}

Here prometheus=ha is the external label. It should be added to the series labels, but not to exemplar labels.

What you expected to happen:
prometheus=ha appears in series labels and doesn't appear in exemplar labels.

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

Successfully merging a pull request may close this issue.

1 participant