Deleting a book first copied its file to a `deleted_` prefix, a support
copy that a lifecycle rule expired after 3 days, and only then deleted
it, all inside the request. With multipart uploads, books of several GB
are common. For a 3 GB book, the server-side copy held the delete for
about a minute, and the apps' serial sync queue waited behind it. The
copy hasn't been needed for support in a long while, so it's gone: the
delete is one DeleteObject.
The 5 GiB fallback that skipped the copy for larger books goes with it.
Why
Deleting a book's file did three steps inside the request:
deleted_<key>, a support copy that theremove-deleted-itemslifecycle rule expired after 3 days;With multipart uploads, books of several GB are now common. For a 3 GB book the server-side copy held the delete for about a minute, and the apps' serial sync queue waited behind it, so a delete looked stuck.
Seen in the iOS device pass: a 3.02 GiB book's delete took about a minute, and its support copy was written as it finished. The copy hasn't been needed for support in a long while.
What
S3Service.deleteFilesends oneDeleteObject, with no copy first.CopyObject, goes with it, along with its HEAD size check.After this deploys, the
remove-deleted-itemslifecycle rule has nothing to act on once the existingdeleted_copies expire, within 3 days. It can then be removed from the bucket; it's harmless if left.Tests
deleteFilesends exactly oneDeleteObjectand copies nothing.deleted_copies were made.