mirror of
https://github.com/prometheus/prometheus
synced 2024-12-23 15:04:13 +00:00
Mixin: Ignore unset remote write timestamp (#8046)
* Mixin: Ignore unset remote write timestamp This pull request ignores the zero value of highest_sent_timestamp_seconds in Highest Timestamp In vs. Highest Timestamp Sent which just show that remote write has not been successful yet. Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
This commit is contained in:
parent
260cd84d8f
commit
4596abee4d
@ -110,7 +110,7 @@ local template = grafana.template;
|
||||
(
|
||||
prometheus_remote_storage_highest_timestamp_in_seconds{cluster=~"$cluster", instance=~"$instance"}
|
||||
-
|
||||
ignoring(remote_name, url) group_right(instance) prometheus_remote_storage_queue_highest_sent_timestamp_seconds{cluster=~"$cluster", instance=~"$instance"}
|
||||
ignoring(remote_name, url) group_right(instance) (prometheus_remote_storage_queue_highest_sent_timestamp_seconds{cluster=~"$cluster", instance=~"$instance"} != 0)
|
||||
)
|
||||
|||,
|
||||
legendFormat='{{cluster}}:{{instance}} {{remote_name}}:{{url}}',
|
||||
@ -124,11 +124,11 @@ local template = grafana.template;
|
||||
)
|
||||
.addTarget(prometheus.target(
|
||||
|||
|
||||
(
|
||||
clamp_min(
|
||||
rate(prometheus_remote_storage_highest_timestamp_in_seconds{cluster=~"$cluster", instance=~"$instance"}[5m])
|
||||
-
|
||||
ignoring (remote_name, url) group_right(instance) rate(prometheus_remote_storage_queue_highest_sent_timestamp_seconds{cluster=~"$cluster", instance=~"$instance"}[5m])
|
||||
)
|
||||
, 0)
|
||||
|||,
|
||||
legendFormat='{{cluster}}:{{instance}} {{remote_name}}:{{url}}',
|
||||
));
|
||||
|
Loading…
Reference in New Issue
Block a user