diff options
author | manuvakery1 <manu.km@idrive.com> | 2020-06-11 20:25:08 +0530 |
---|---|---|
committer | manuvakery1 <manu.km@idrive.com> | 2020-06-12 13:02:18 +0530 |
commit | 6afefe1ad34cc5eb6625308296b67e952e07329f (patch) | |
tree | 40096403f5ce2c21fb6a2476fca936dac74aa146 /swift/common/middleware/s3api/s3request.py | |
parent | 0b86f681f5e225854b6e66f3e5f2295e9ff3107e (diff) | |
download | swift-6afefe1ad34cc5eb6625308296b67e952e07329f.tar.gz |
s3api: Add basic support for ?tagging requests
https://docs.aws.amazon.com/cli/latest/userguide/cliv2-migration.html#cliv2-migration-s3-copy-metadata
AWS CLI version 2 improves Amazon S3 handling of file properties
and tags when performing multipart copies. We still don't supprt
object tagging hence the aws s3 cp command fails for mulitpart
copies with default options.
This way get tagging request will receive an empty tagset in
response and mulitpart copies will work fine
Change-Id: I1f031b05025cafac00e86966c240aa5f7258d0bf
Diffstat (limited to 'swift/common/middleware/s3api/s3request.py')
-rw-r--r-- | swift/common/middleware/s3api/s3request.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/swift/common/middleware/s3api/s3request.py b/swift/common/middleware/s3api/s3request.py index 28e734f0b..7e80547dc 100644 --- a/swift/common/middleware/s3api/s3request.py +++ b/swift/common/middleware/s3api/s3request.py @@ -45,7 +45,8 @@ from swift.common.middleware.s3api.controllers import ServiceController, \ ObjectController, AclController, MultiObjectDeleteController, \ LocationController, LoggingStatusController, PartController, \ UploadController, UploadsController, VersioningController, \ - UnsupportedController, S3AclController, BucketController + UnsupportedController, S3AclController, BucketController, \ + TaggingController from swift.common.middleware.s3api.s3response import AccessDenied, \ InvalidArgument, InvalidDigest, BucketAlreadyOwnedByYou, \ RequestTimeTooSkewed, S3Response, SignatureDoesNotMatch, \ @@ -1026,9 +1027,11 @@ class S3Request(swob.Request): return UploadsController if 'versioning' in self.params: return VersioningController + if 'tagging' in self.params: + return TaggingController unsupported = ('notification', 'policy', 'requestPayment', 'torrent', - 'website', 'cors', 'tagging', 'restore') + 'website', 'cors', 'restore') if set(unsupported) & set(self.params): return UnsupportedController |