HomePhabricator
Diffusion Comm 4f2c8b6b4af4

[keyserver] Remove holders in upload deleters

Description

[keyserver] Remove holders in upload deleters

Summary:
Address ENG-9352.
Before calling DELETE FROM uploads, we need to select the extra column first and remove blob holders if present in the column JSON.

Depends on D13511

Test Plan:
Used local Blob Service for testing.

For deleteUpload, used the delete_upload keyserver endpoint (easy way is canceling media message on web, with blob uploads enabled). Called the endpoint and verified that blob associated with the upload was deleted from DDB.

For deleting unassigned uploads: Manually modified MariaDB by setting containers to null and age to be older than 24h. Modified the cron job call to instead run during keyserver startup. Verified that holders were removed.

Reviewers: tomek, ashoat

Reviewed By: ashoat

Differential Revision: https://phab.comm.dev/D13512

Details

Provenance
bartekAuthored on Sep 30 2024, 2:04 AM
Reviewer
ashoat
Differential Revision
D13512: [keyserver] Remove holders in upload deleters
Parents
rCOMM7d84edf2d087: [keyserver][lib] Blob client function to remove multiple holders
Branches
Unknown
Tags
Unknown