mirror of https://github.com/minio/minio.git
Avoid listing buckets from a suspended pool (#15283)
Make bucket requests sent after decommissioning is started are not created in a suspended pool. Therefore listing buckets should avoid suspended pools as well.
This commit is contained in:
parent
0a8b78cb84
commit
996cac5fed
|
@ -1652,7 +1652,10 @@ func (z *erasureServerPools) ListBuckets(ctx context.Context) (buckets []BucketI
|
|||
if z.SinglePool() {
|
||||
buckets, err = z.serverPools[0].ListBuckets(ctx)
|
||||
} else {
|
||||
for _, pool := range z.serverPools {
|
||||
for idx, pool := range z.serverPools {
|
||||
if z.IsSuspended(idx) {
|
||||
continue
|
||||
}
|
||||
buckets, err = pool.ListBuckets(ctx)
|
||||
if err != nil {
|
||||
logger.LogIf(ctx, err)
|
||||
|
|
Loading…
Reference in New Issue