Skip to content

Commit

Permalink
Increase the buffer size of objects channel in removeObjectsOneByOne
Browse files Browse the repository at this point in the history
I guess this is pretty reasonable to have the working queue with the same
size as the maximum number of workers.
  • Loading branch information
a-narsudinov committed Oct 27, 2023
1 parent d3e89f1 commit 6a7b88e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/s3/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ func (client *s3Client) removeObjects(bucketName, prefix string) error {
// will delete files one by one without file lock
func (client *s3Client) removeObjectsOneByOne(bucketName, prefix string) error {
parallelism := 16
objectsCh := make(chan minio.ObjectInfo, 1)
objectsCh := make(chan minio.ObjectInfo, parallelism)
guardCh := make(chan int, parallelism)
var listErr error
var totalObjects int64 = 0
Expand Down

0 comments on commit 6a7b88e

Please sign in to comment.