Skip to content

Conversation

@QuentinBisson
Copy link
Contributor

PR Description

The goal is to allow loki.rules.kubernetes to add extra matchers to queries to align with this PR #1773 that was done for mimir.rules.kubernetes.

Which issue(s) this PR fixes

Notes to the Reviewer

I tried to copy the same structure as the code in the mimir.rules.kubernetes component changing mostly the parsing code (using logql instead) which was quite fun to do.

There might be similarities between the 2 code bases that might require some code sharing in places but with the upcoming PRs that I opened for the mimir.rules.kubernetes component (#3270 and #3175), I feel like it might be better to refactor this later one.

PR Checklist

  • CHANGELOG.md updated
  • Documentation added
  • Tests updated
  • Config converters updated

@QuentinBisson QuentinBisson requested review from a team and clayton-cornell as code owners April 16, 2025 20:55
@QuentinBisson QuentinBisson force-pushed the support-extra-labels-on-loki-rule-queries branch from 5fb36c2 to 786a71f Compare April 16, 2025 21:34
@QuentinBisson
Copy link
Contributor Author

Thank you for the review @clayton-cornell :)

@clayton-cornell
Copy link
Contributor

Over to @grafana/grafana-agent-maintainers fr a code review now :-)

@clayton-cornell clayton-cornell requested a review from a team May 12, 2025 19:02
Copy link
Contributor

@wildum wildum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for bringing this change to loki.rules.kubernetes. I only have two small comments about the error handling part of the code.

Copy link
Contributor

@wildum wildum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@wildum wildum merged commit eae79a7 into grafana:main May 13, 2025
35 of 36 checks passed
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 13, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

frozen-due-to-age type/docs Docs Squad label across all Grafana Labs repos

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants