Skip to content

Update assignment of prometheus variables

Sean Arnold requested to merge sarnold-fix-prom-alerts-config into master

What does this MR do?

It seems as though since !31362 (merged) the variable substitution has been broken when creating Prometheus Alerts through the GitLab UI.

Running Clusters::ApplicationsPrometheusConfigService doesn't seem to substitute the params anymore.

Cause:

Previously we were using String#% to replace the strings which expects the input string to contain %{var_to_replace}. As this format was removed in the MR we encounter the issue.

Does this MR meet the acceptance criteria?

Conformity

Closes #220144 (closed)

Edited by 🤖 GitLab Bot 🤖

Merge request reports