-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Rule: Add linting command for prometheus rules #1096
Comments
I'll do this, just creating an issue if someone else hits this too. |
Makes complete sense, thank you for doing this! However, I wonder if it would be better to move such functionality to separate binary file like |
This is valid point. We quickly acked this naming on slack with @bwplotka but if we agree than it can refactore it to separate tool. But on the other hand the bucket commands are already there so if we decide to split it if would feel correct to take those commands out also. |
If we seperate it out into different tools, |
What's the point of separation? I think the single binary is quite a nice feature, as we have a single Go binary for everything, simple build step simplifies all. Unless separation which gives us advantage like some separation of sensitivity or majority reduced binary size I don't see the benefit in splitting TBH (: But interested to see other points of views! |
We can move the ls, bucket, linter functionalities to separate Golang package, and just hook it from single cmd/thanos package if that helps in organizing code ? |
For me it's also ok to leave it in the one binary. |
Yeah I love our mono binary as well, and we should definitely figure a good package structure, so that people can import and extend if they need to :) |
I don't have any strong opinions, just thought that maybe it would be worth to stop for a second and think about it. I am fine either way - I like the mono binary too! 😄 |
Thanos rule has additional config
partial_response_strategy
for rule groups in the rules file.Prometheus unfortunately uses strict yaml unmarshaling so the
promtool check rules ...
fails with:Possible solution could be adding own rule lint command to the thanos like
thanos check rules
which would check the syntax valid for thanos-rule.The text was updated successfully, but these errors were encountered: