May 2019
Intermediate to advanced
442 pages
11h 36m
English
Logical operators are most easily understood as their set theory counterparts, as shown in the following table. These operators are the only ones in PromQL that work many-to-many. There are three logical operators that can be used between expressions:
|
Operator |
Description |
|
and |
Intersection |
|
or |
Union |
|
unless |
Complement |
The and logical operator works by only returning the matches from the left-hand side if the expression on the right-hand side has results with matching label key/value pairs. All other time series from the left-hand side that do not have a match on the right-hand side are dropped. The resulting time series will keep the name from the left operand. This is why it is also called the ...
Read now
Unlock full access