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 (optional) names to routes #3820

Conversation

grobinson-grafana
Copy link
Contributor

@grobinson-grafana grobinson-grafana commented Apr 25, 2024

This pull request adds (optional) names to routes to fix #3817. In the case where a user has two routes with the same receiver, matchers and group by, a name can be used to ensure their groups have unique group keys and avoid using the same nflog.

This commit adds (optional) names to routes to fix prometheus#3817.
In the case where a user has two routes with the same
receiver, matchers and group_by, a name can be used to
ensure their groups have unique group keys and avoid using
the same nflog.

Signed-off-by: George Robinson <george.robinson@grafana.com>
@simonpasquier
Copy link
Member

It implies that the user knows in advance that 2 routes are going to create identical group keys? It doesn't seem to me a nice user experience.

What if Alertmanager adds the route index when it suspects a possible conflict? Would it solve the problem?

@grobinson-grafana
Copy link
Contributor Author

What if Alertmanager adds the route index when it suspects a possible conflict? Would it solve the problem?

That's what we tried here, but it has unintended side effects. For example, if a new route is added to the beginning of the list of routes then it invalidates the nflogs for all other routes as all the indexes will change.

@grobinson-grafana grobinson-grafana deleted the grobinson/add-route-name branch June 25, 2024 15:59
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 this pull request may close these issues.

How to fix non unique GroupKeys?
2 participants