using /v1/tenant endpoint is actually not necessary, we don't care about status 503

This commit is contained in:
Christian Schwarz
2024-01-25 15:48:54 +00:00
parent 50c4b83066
commit 9fae0d9562

View File

@@ -237,14 +237,13 @@ impl PageServerNode {
background_process::InitialPidFile::Expect(self.pid_file()),
|| async {
let res =
tokio::time::timeout(Duration::from_secs(1), self.http_client.list_tenants())
.await;
tokio::time::timeout(Duration::from_secs(1), self.http_client.status()).await;
match res {
Ok(res) => match res {
Ok(_) => Ok(true),
Err(e) => match e {
mgmt_api::Error::ReceiveBody(e) => {
if e.is_connect() || e.is_timeout() {
if e.is_connect() {
Ok(false)
} else {
Ok(true)