From 5f13c519ee2993eda33d762788170c9ca16f5dba Mon Sep 17 00:00:00 2001 From: Aliaksandr Valialkin Date: Sun, 15 Aug 2021 16:03:54 +0300 Subject: [PATCH] lib/promscrape: restore red highlighting for DOWN targets at /targets page Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1461 --- docs/CHANGELOG.md | 1 + lib/promscrape/targets_response.qtpl | 2 +- lib/promscrape/targets_response.qtpl.go | 2 ++ 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 9658e0411a..ad4942cecc 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -26,6 +26,7 @@ sort: 15 * BUGFIX: vmselect: prevent from possible deadlock when multiple `target` query args are passed to [Graphite Render API](https://docs.victoriametrics.com/#graphite-render-api-usage). * BUGFIX: return series with `a op b` labels and `N` values for `(a op b) default N` if `(a op b)` returns series with all NaN values. Previously such series were removed. * BUGFIX: vmui: fix layout when the query selects more than 27 time series. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1497). +* BUGFIX: vmagent: restore highlighting in red for DOWN targets at `/targets` page. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1461). ## [v1.63.0](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.63.0) diff --git a/lib/promscrape/targets_response.qtpl b/lib/promscrape/targets_response.qtpl index d5affb402c..448012c736 100644 --- a/lib/promscrape/targets_response.qtpl +++ b/lib/promscrape/targets_response.qtpl @@ -74,7 +74,7 @@ job={%q= jobName %} (0/0 up) {% for _, ts := range js.targetsStatus %} {% if onlyUnhealthy && ts.up %}{% continue %}{% endif %} - + {%s ts.endpoint %}
{% if ts.up %}UP{% else %}DOWN{% endif %} diff --git a/lib/promscrape/targets_response.qtpl.go b/lib/promscrape/targets_response.qtpl.go index 2d19d3bde6..334d1873f0 100644 --- a/lib/promscrape/targets_response.qtpl.go +++ b/lib/promscrape/targets_response.qtpl.go @@ -258,6 +258,8 @@ func StreamTargetsResponseHTML(qw422016 *qt422016.Writer, jts []jobTargetsStatus qw422016.N().S(`