make sure to set Versioned field to ensure rename2 is not called (#18141)

without this the rename2() can rename the previous dataDir
causing issues for different versions of the object, only
latest version is preserved due to this bug.

Added healing code to ensure recovery of such content.
This commit is contained in:
Harshavardhana
2023-09-29 09:08:24 -07:00
committed by GitHub
parent dd8547e51c
commit c34bdc33fb
3 changed files with 44 additions and 8 deletions

View File

@@ -955,6 +955,8 @@ func (api objectAPIHandlers) CompleteMultipartUploadHandler(w http.ResponseWrite
writeErrorResponse(ctx, w, toAPIError(ctx, err), r.URL)
return
}
opts.Versioned = versioned
opts.VersionSuspended = suspended
// First, we compute the ETag of the multipart object.
// The ETag of a multi-part object is always: