Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use the Prometheus /-/healthy endpoint for the default value for health_check_url #6966

Closed
jmazzitelli opened this issue Dec 18, 2023 · 0 comments · Fixed by #6969
Closed
Assignees
Labels
backlog Triaged Issue added to backlog backport completed Issue PRs have been backported backport needed Issue PRs require backport to versions specified in comments enhancement This is the preferred way to describe new end-to-end features.

Comments

@jmazzitelli
Copy link
Collaborator

by default, use the /-/healthy endpoint that Prometheus has, rather than the main prometheus root url.

This is because sometimes Prometheus doesn't have the UI installed and this causes the root URL to tell the client to redirect to an invalid /graph endpoint, causing a error code to be returned, thus Kiali UI will report Prometheus being unreachable which isn't true.

For example, in one setup we've seen in testing, this happens.

If I go into the prometheus pod itself, and try to submit a request to check its health (using curl), I get this:

curl -k -u internal:DiQkSCH6Y/DManOj8HI7S..[chomp]..qQ6AsJxTEI3 https://prometheus.istio-system.svc:9090/
<a href="/graph">Found</a>.

Which looks fine, but that is actually returning a 302 - it is redirecting the client to /graph and if I go to the /graph path I see this:

curl -k -q -u internal:DiQkSCH6Y/DManOj8HI7S..[chomp]..qQ6AsJxTEI3 https://prometheus.istio-system.svc:9090/graph
Error opening React index.html: open web/ui/static/react/index.html: no such file or directory

and that returns a error code of 500, which results in the Kiali UI to report Prometheus as "unreachable". But that is not true. Kiali UI can show the graph and metrics fine. This is because the Prometheus backend is working fine, it is just the Prometheus UI isn't installed or configured properly. But Kiali doesn't care about that - it just cares that Prometheus can respond to our queries (which it can in this particular case).

@jmazzitelli jmazzitelli added the enhancement This is the preferred way to describe new end-to-end features. label Dec 18, 2023
@jmazzitelli jmazzitelli self-assigned this Dec 18, 2023
@jmazzitelli jmazzitelli added the backlog Triaged Issue added to backlog label Dec 18, 2023
jmazzitelli added a commit to jmazzitelli/kiali that referenced this issue Dec 18, 2023
@jmazzitelli jmazzitelli added the backport needed Issue PRs require backport to versions specified in comments label Dec 18, 2023
jmazzitelli added a commit to jmazzitelli/kiali that referenced this issue Dec 18, 2023
@jmazzitelli jmazzitelli added the backport completed Issue PRs have been backported label Dec 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog Triaged Issue added to backlog backport completed Issue PRs have been backported backport needed Issue PRs require backport to versions specified in comments enhancement This is the preferred way to describe new end-to-end features.
Projects
Development

Successfully merging a pull request may close this issue.

1 participant