mirror of
https://github.com/minio/minio.git
synced 2025-01-11 23:13:23 -05:00
fix: readiness should return 200 OK with first zone online (#8834)
This commit is contained in:
parent
c18fbdb29a
commit
c6b218e5df
@ -1372,15 +1372,7 @@ func (z *xlZones) GetMetrics(ctx context.Context) (*Metrics, error) {
|
|||||||
return &Metrics{}, NotImplemented{}
|
return &Metrics{}, NotImplemented{}
|
||||||
}
|
}
|
||||||
|
|
||||||
// IsReady - Returns True if all the zones have enough quorum to accept requests.
|
// IsReady - Returns true if first zone returns true
|
||||||
func (z *xlZones) IsReady(ctx context.Context) bool {
|
func (z *xlZones) IsReady(ctx context.Context) bool {
|
||||||
if z.SingleZone() {
|
return z.zones[0].IsReady(ctx)
|
||||||
return z.zones[0].IsReady(ctx)
|
|
||||||
}
|
|
||||||
for _, xlsets := range z.zones {
|
|
||||||
if !xlsets.IsReady(ctx) {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user