support cancelling of multipart upload
This commit is contained in:
parent
6e65b5f6d4
commit
b1d59c7e17
2 changed files with 8 additions and 0 deletions
|
|
@ -188,6 +188,10 @@ def _key_response(request, full_url, headers):
|
|||
else:
|
||||
return 404, headers, ""
|
||||
elif method == 'DELETE':
|
||||
if 'uploadId' in query:
|
||||
upload_id = query['uploadId'][0]
|
||||
s3_backend.cancel_multipart(bucket_name, upload_id)
|
||||
return 204, headers, ""
|
||||
removed_key = s3_backend.delete_key(bucket_name, key_name)
|
||||
template = Template(S3_DELETE_OBJECT_SUCCESS)
|
||||
return 204, headers, template.render(bucket=removed_key)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue