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

Show offending labels in many-to-many error #4608

Closed
matthiasr opened this Issue Sep 14, 2018 · 6 comments

Comments

Projects
None yet
6 participants
@matthiasr
Copy link
Contributor

matthiasr commented Sep 14, 2018

Proposal

When showing the error message

Error executing query: many-to-many matching not allowed: matching labels must be unique on one side

include the labels, and potentially even the whole metric, that caused it.

Use case. Why is this important?

I just spent half an hour staring at a query trying to fix this issue; sometimes a very large set of time series has duplication in only a handful of them. Knowing more about the reason for the many-to-many error would have helped a lot.

This message is generated here:

ev.errorf("many-to-many matching not allowed: matching labels must be unique on one side")

@trajano

This comment has been minimized.

Copy link

trajano commented Dec 27, 2018

While we're waiting for a fix. how did you debug your query to find out?

@matthiasr

This comment has been minimized.

Copy link
Contributor Author

matthiasr commented Dec 27, 2018

I aggregated away different labels on both sides until I found which one is causing the issue, then thought about how many-to-many matches could arise based on how the metrics were generated and collected. As I wrote, there's no clever way but to think about it really hard.

@dnwe

This comment has been minimized.

Copy link

dnwe commented Dec 27, 2018

I hit the same issue. I just manually patched engine.go to print out details of the label collision and ran my queries through that to see which were the cause

@matthiasr

This comment has been minimized.

Copy link
Contributor Author

matthiasr commented Dec 28, 2018

@tariq1890

This comment has been minimized.

Copy link
Contributor

tariq1890 commented Feb 6, 2019

I can take this issue up.

@juliusv

This comment has been minimized.

Copy link
Member

juliusv commented Feb 6, 2019

@tariq1890 Please do!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.