Hi,

I'm using swift-account-reaper for accounts with buckets in an unsharded
state, and it looks fine, wiping the account. But when I try to wipe an
account with sharded buckets, I encounter some problematic scenarios.

First, when deleting the account, account-reaper lists objects from the
sharded bucket, an empty list is returned from direct_get_container function,
so the reaper interprets it as an empty bucket, and the delete fails
with a 409 Conflict because objects exist inside the bucket.

My second thought was to delete the account that holds shard buckets
(i.e. .shards_AUTH_<project_id>) so the reaper will wipe this account.
Then, with all buckets empty, they'll be deleted from the principal
account (AUTH_<project_id>). But in this case, when the reaper tries to
delete objects inside this account, all objects are not found because
the object path used is "/.shards_AUTH_<project_id>/<bucket>-<hash>-
<timestamp>-<shard_index>/<key>" instead of "/AUTH_<project_id>/
<bucket>/<key>".

Am I doing something wrong in trying to delete this account? Or does
account-reaper, in fact, not support sharded buckets? I'm exploring some
patches to make it work, and I can volunteer to work on this fix if
necessary.

Thanks!



‘Esta mensagem é direcionada apenas para os endereços constantes no cabeçalho inicial. Se você não está listado nos endereços constantes no cabeçalho, pedimos-lhe que desconsidere completamente o conteúdo dessa mensagem e cuja cópia, encaminhamento e/ou execução das ações citadas estão imediatamente anuladas e proibidas’.

 ‘Apesar do Magazine Luiza tomar todas as precauções razoáveis para assegurar que nenhum vírus esteja presente nesse e-mail, a empresa não poderá aceitar a responsabilidade por quaisquer perdas ou danos causados por esse e-mail ou por seus anexos’.