From b85fc39bdb49cd19fea4e6bab6d3cec52d9ca471 Mon Sep 17 00:00:00 2001 From: Heikki Linnakangas Date: Mon, 6 Nov 2023 09:26:09 +0200 Subject: [PATCH] Update control plane API path for getting compute spec. (#5357) We changed the path in the control plane. The old path is still accepted for compatibility with existing computes, but we'd like to phase it out. --- compute_tools/src/spec.rs | 2 +- test_runner/regress/test_ddl_forwarding.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/compute_tools/src/spec.rs b/compute_tools/src/spec.rs index 3fa3cf055fec..a85d6287b17d 100644 --- a/compute_tools/src/spec.rs +++ b/compute_tools/src/spec.rs @@ -68,7 +68,7 @@ pub fn get_spec_from_control_plane( base_uri: &str, compute_id: &str, ) -> Result> { - let cp_uri = format!("{base_uri}/management/api/v2/computes/{compute_id}/spec"); + let cp_uri = format!("{base_uri}/compute/api/v2/computes/{compute_id}/spec"); let jwt: String = match std::env::var("NEON_CONTROL_PLANE_TOKEN") { Ok(v) => v, Err(_) => "".to_string(), diff --git a/test_runner/regress/test_ddl_forwarding.py b/test_runner/regress/test_ddl_forwarding.py index 6bd09c703055..07ee8b405e9e 100644 --- a/test_runner/regress/test_ddl_forwarding.py +++ b/test_runner/regress/test_ddl_forwarding.py @@ -72,7 +72,7 @@ def __init__(self, httpserver: HTTPServer, vanilla_pg: VanillaPostgres, host: st self.dbs: Dict[str, str] = {} self.roles: Dict[str, str] = {} self.fail = False - endpoint = "/management/api/v2/roles_and_databases" + endpoint = "/test/roles_and_databases" ddl_url = f"http://{host}:{port}{endpoint}" self.pg.configure( [