Skip to content

Commit 329f73b

Browse files
authored
fix(dre): migrate away from node-list endpoint (#1923)
1 parent 40dad4b commit 329f73b

File tree

2 files changed

+13
-11
lines changed

2 files changed

+13
-11
lines changed

Cargo.lock

Lines changed: 9 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rs/ic-management-backend/src/health.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ impl PublicDashboardHealthClient {
173173

174174
fn api_node_list(&self) -> anyhow::Result<Url> {
175175
self.base_url
176-
.join("/api/node-list")
176+
.join("/api/v3/nodes")
177177
.map_err(|e| anyhow::anyhow!("Error joining url: {:?}", e))
178178
}
179179

@@ -188,7 +188,9 @@ impl PublicDashboardHealthClient {
188188
.client
189189
.execute(request)
190190
.await
191-
.map_err(|e| anyhow::anyhow!("Error while fetching data from public dashboard: {:?}", e))?;
191+
.map_err(|e| anyhow::anyhow!("Error while fetching data from public dashboard: {:?}", e))?
192+
.error_for_status()
193+
.map_err(|e| anyhow::anyhow!("Error while fetching data from public dashboard, response: {e:?}"))?;
192194

193195
let response_text = response.text().await.map_err(|e| anyhow::anyhow!("Error reading response text: {}", e))?;
194196
let response: Value = serde_json::from_str(&response_text)

0 commit comments

Comments
 (0)