Skip to content

Rescue from network errors when querying Prometheus in the background

Dominic Bauer requested to merge 341633-statistics-page-not-loading into master

What does this MR do and why?

Currently PrometheusAdapter can fail to update its reactive cache when encountering unhandled network errors.

This is because only a subset of all possible errors in Gitlab::HTTP::HTTP_ERRORS is handled by Gitlab::PrometheusClient#get.

This MR rectifies this by making PrometheusClient reraise all HTTP_ERRORS as PrometheusClient::Error.

Screenshots or screen recordings

Refer to: #341633 (comment 714590480)

How to set up and validate locally

Refer to: #341633 (comment 714590480)

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #341633 (closed)

Edited by Dominic Bauer

Merge request reports