From fd2959fa3a4254ba899657004bbe10ce780f43b7 Mon Sep 17 00:00:00 2001 From: jiuker <2818723467@qq.com> Date: Tue, 16 May 2023 23:08:00 +0800 Subject: [PATCH] fix: workers.New err must be returned (#17208) --- cmd/bucket-lifecycle.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmd/bucket-lifecycle.go b/cmd/bucket-lifecycle.go index 1bb5b8751..4f4cbdda4 100644 --- a/cmd/bucket-lifecycle.go +++ b/cmd/bucket-lifecycle.go @@ -153,7 +153,9 @@ func initBackgroundExpiry(ctx context.Context, objectAPI ObjectLayer) { globalExpiryState = newExpiryState() workerSize, _ := strconv.Atoi(env.Get("_MINIO_ILM_EXPIRY_WORKERS", strconv.Itoa((runtime.GOMAXPROCS(0)+1)/2))) - + if workerSize == 0 { + workerSize = 4 + } ewk, err := workers.New(workerSize) if err != nil { logger.LogIf(ctx, err)