Alert vertical line annotations showing even when related resources are not visualzied

I’m trying to understand how alerting works and how it is visualized.

I have an alert configuration that is tied to a panel. The panel is on a postgresql dashboard and it’s visualizing a single postgres metric:


The alert is on the same metric but without {datname="$db"} because that seemed to make the alert query return no results.

I’m slightly confused because it looks like the vertical line annotations related to the alert are always visualized on the panel, regardless of which database is selected on the dashboard. I’m not sure how to address this.

Can you confirm: are you using the new Unified Alerting platform or the legacy platform?