allow concurrent aborts on active uploadParts() (#21229)

allow aborting on active uploads in progress, however fail these
uploads subsequently during commit phase and return appropriate errors
This commit is contained in:
jiuker
2025-04-25 13:41:04 +08:00
committed by GitHub
parent b7540169a2
commit ddd9a84cd7
9 changed files with 60 additions and 18 deletions

View File

@@ -760,7 +760,7 @@ func (client *storageRESTClient) DeleteVersions(ctx context.Context, volume stri
}
// RenamePart - renames multipart part file
func (client *storageRESTClient) RenamePart(ctx context.Context, srcVolume, srcPath, dstVolume, dstPath string, meta []byte) (err error) {
func (client *storageRESTClient) RenamePart(ctx context.Context, srcVolume, srcPath, dstVolume, dstPath string, meta []byte, skipParent string) (err error) {
ctx, cancel := context.WithTimeout(ctx, globalDriveConfig.GetMaxTimeout())
defer cancel()
@@ -771,6 +771,7 @@ func (client *storageRESTClient) RenamePart(ctx context.Context, srcVolume, srcP
DstVolume: dstVolume,
DstFilePath: dstPath,
Meta: meta,
SkipParent: skipParent,
})
return toStorageErr(err)
}