Added
-
Added
--checkstyle
flag topint lint
&pint ci
for writing XML report file
incheckstyle
format - #1129. -
Added
--json
flag to bothpint lint
andpint ci
commands, this enables writing a JSON file
with the report of all problems #606. -
promql/fragile will now warn when alerting rules are using
one of the aggregation operation that can return different series on every evaluation,
which can cause alert floppiness - #820. -
promql/regexp check now supports extra configuration options
to disable reports on smelly selector - #1096. -
Checks can be enabled or disabled specifically for some Prometheus rules via
rule {}
config blocks.
Addingenable
ordisable
option with a list of checks names allows to selectively enable or disable
checks only for Prometheus rules that match givenrule {}
definition.
Enabling checks only for matching rules will only work if these checks are disabled globally via
check { disabled = [] }
config block.
For example to disablepromql/rate
check for all rules except alerting rules in therules/critical
folder:checks { // This will disable promql/rate by default. disabled = [ "promql/rate" ] } rule { match { path = "rules/critical/.*" kind = "alerting" } // This will enable promql/rate only for Prometheus rules matching all our match conditions above. enable = [ "promql/rate" ] }
Changed
- alerts/template check was refactored and will now produce more accurate results.
Messages produced by this check might include details of the PromQL query fragment causing the problem
if the query is complex enough.
Fixed
- Don't try to create GitLab comments on unmodified lines - #1147.