From 2825294b7b7d6d7ee9460a45296a77b689d7ae40 Mon Sep 17 00:00:00 2001 From: Harshavardhana Date: Wed, 19 Jun 2024 22:21:31 -0700 Subject: [PATCH] allow server startup to come online with READ success (#19957) --- cmd/erasure-server-pool.go | 1 - cmd/server-main.go | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/cmd/erasure-server-pool.go b/cmd/erasure-server-pool.go index 5b8b2a88c..69f6d84f0 100644 --- a/cmd/erasure-server-pool.go +++ b/cmd/erasure-server-pool.go @@ -2425,7 +2425,6 @@ const ( type HealthOptions struct { Maintenance bool DeploymentType string - Startup bool } // HealthResult returns the current state of the system, also diff --git a/cmd/server-main.go b/cmd/server-main.go index 9073e672e..e707c96b4 100644 --- a/cmd/server-main.go +++ b/cmd/server-main.go @@ -921,14 +921,14 @@ func serverMain(ctx *cli.Context) { } bootstrapTrace("waitForQuorum", func() { - result := newObject.Health(context.Background(), HealthOptions{Startup: true}) - for !result.Healthy { + result := newObject.Health(context.Background(), HealthOptions{}) + for !result.HealthyRead { if debugNoExit { logger.Info("Not waiting for quorum since we are debugging.. possible cause unhealthy sets (%s)", result) break } d := time.Duration(r.Float64() * float64(time.Second)) - logger.Info("Waiting for quorum healthcheck to succeed.. possible cause unhealthy sets (%s), retrying in %s", result, d) + logger.Info("Waiting for quorum READ healthcheck to succeed.. possible cause unhealthy sets (%s), retrying in %s", result, d) time.Sleep(d) result = newObject.Health(context.Background(), HealthOptions{}) }