Swift: Add "bulk-delete" URL argument support#1930
Swift: Add "bulk-delete" URL argument support#1930jtopjian merged 1 commit intogophercloud:masterfrom
Conversation
|
Build succeeded.
|
|
@jtopjian ready for review |
|
We should be able to easily add an acceptance test for this, right? Let me know if you need help. |
|
@jtopjian just noticed that bulk-delete is also valid for containers. It would be great if you help me with acceptance tests. |
06c6a46 to
07cf4b8
Compare
|
Build failed.
|
07cf4b8 to
81c85d3
Compare
|
Build succeeded.
|
|
According to https://github.com/openstack/swift/blob/a495f1e327fac17246a296721fb1eda8470e4773/swift/common/middleware/bulk.py#L156..L194, bulk delete should have a |
Right. Now I recall that I looked into this in the past and silently backed away 🙂 This means that we'll need to modify In addition, an actual structured response body is sent back, which differs from a normal Swift response where the bulk of the info is in the headers: https://docs.openstack.org/ocata/user-guide/cli-swift-bulk-delete.html In my opinion, a better approach might be to make entirely new functions/actions called
Finally, I think a 409 response (I think this means that only some of the requested containers/objects were deleted) might be a little common and we should either consider treating it as valid response code... but I'm not 100% sure on this, yet. Thoughts? |
|
@jtopjian no concerns, though at first glance it looked like a low hanging fruit. |
81c85d3 to
5a598bc
Compare
5a598bc to
b0d9caa
Compare
|
Build succeeded.
|
|
@jtopjian I reworked the PR. I also discovered and fixed redundant pointers usage and unencoded container/object names. |
|
@jtopjian can you add a release note that container and object names are now urlencoded? |
|
Sure - but we should try to have things like this in separate PRs. |
Resolves #1721
https://github.com/openstack/swift/blob/a495f1e327fac17246a296721fb1eda8470e4773/swift/common/middleware/bulk.py#L740
Response dict: https://github.com/openstack/swift/blob/a495f1e327fac17246a296721fb1eda8470e4773/swift/common/middleware/bulk.py#L413