Skip to content

Commit

Permalink
added expressionWithNoMetricName to docs
Browse files Browse the repository at this point in the history
  • Loading branch information
tizki committed Dec 6, 2023
1 parent 083429c commit 322dc93
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion docs/validations.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@
- [expressionCanBeEvaluated](./validations.md#expressioncanbeevaluated)
- [expressionUsesExistingLabels](./validations.md#expressionusesexistinglabels)
- [expressionSelectorsMatchesAnything](./validations.md#expressionselectorsmatchesanything)
-
- [expressionWithNoMetricName]
-
- [Alert](#alert)
- [forIsNotLongerThan](./validations.md#forisnotlongerthan)

Expand Down Expand Up @@ -264,6 +265,12 @@ Fails if any used label is not present in the configured Prometheus instance.
Verifies if any of the selectors in the expression (eg `up{foo="bar"}`) matches actual data in the configured Prometheus
instance.

### `expressionWithNoMetricName`

> Fails if an expression doesn't use an explicit metric name.

Verifies that any of the selectors in the expression (eg `up{foo="bar"}`) has a metric name. The metric name can appear before the curly braces or in `__name__` label. Fails if an expressions doesn't have a metric name.

## Alert

### `forIsNotLongerThan`
Expand Down

0 comments on commit 322dc93

Please sign in to comment.