fix(dashboard): derive api Services latency_url from api_http_addr (closes #164)#165
Open
kiannidev wants to merge 1 commit into
Open
fix(dashboard): derive api Services latency_url from api_http_addr (closes #164)#165kiannidev wants to merge 1 commit into
kiannidev wants to merge 1 commit into
Conversation
Add Config::api_status_url() and use it in dashboard_service_targets so bare or stale [services.api].url values still probe the bound API. Closes GeniePod#164
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Config::api_status_url()ingenie-common→http://{api_http_addr()}/api/status.dashboard_service_targets()usesapi_status_url()for the api row instead of raw[services.api].url(core already usescore_health_url()from[services.core].urldrifts from[core].port— health monitor and dashboard probe wrong port #121).127.0.0.1:4080/api/status) and dashboard target URL.Closes #164
Real Behavior Proof
What I ran
What I observed
All tests passed. With
[services.api].url = "127.0.0.1:4080/api/status", dashboard latency probe useshttp://127.0.0.1:4080/api/statusinstead of the raw TOML string.Test plan
cargo test -p genie-common api_status_urlcargo test -p genie-api dashboard_api_target dashboard_core_targetcargo fmt --all -- --checkcurldashboard/api/services, api row healthy when genie-api listens