Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Alert policies: ${metric.label.value} null for promQL policies

I have several promql alert policies.

Sample request:

round(histogram_quantile(0.99, increase(run_googleapis_com:container_cpu_utilizations_bucket{monitored_resource="cloud_run_revision"}[1m])) * 100 , 0.01) > 90

The result returned is done as expected ( a list of fields + "Value" variable well defined)

On the alert policy, I have a documentation text field containing:

The cloud run CPU utilization for [${resource.label.revision_name}] has exceeded 90% for over 5 minutes. Current CPU usage is [${metric.label.value}%]

When the alert trigger is reach, the alert is created (incident creation OK).

The variable ${resource.label.revision_name} is well defined with the field value for the could run revision name as expected but the field concerning ${metric.label.value} is replaced by "Null" rather thant the promql  value that trigger the alert...

The cloud run CPU utilization for [my_ressource_name] has exceeded 90% for over 5 minutes. Current CPU usage is [(Null)%]

Several months ago, I designed about 20 promql policies like that (cpu / ram / network parameters etc...) , the variable ${metric.label.value} was always well defined with the promql value.

Since several days or weeks (i don't know exactly), the returned value for ${metric.label.value} is always "Null" even if the data is well returned by the promql request.

Can you tell me if Google has updated the way they manage the Value field for promql queries ? The GCP documentation about variables confirms that ${metric.label.value} stays the solution to put the promql "Value" field in the documentation.

Many thx for your help, I'm stuck in this since several days ! 🙂

Chris

PromQL request:

Policy configuration 1.jpg

Returned data:

capture returned value.jpg

Documentation field defined:

Documentation text field.jpg

0 0 5
0 REPLIES 0
Top Solution Authors