Page MenuHomePhabricator

Support storage of Differential hunk data in Files
ClosedPublic

Authored by epriestley on Sep 11 2017, 3:31 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Nov 21, 8:20 AM
Unknown Object (File)
Tue, Nov 12, 6:55 AM
Unknown Object (File)
Thu, Oct 31, 2:02 AM
Unknown Object (File)
Sep 22 2024, 10:50 AM
Unknown Object (File)
Sep 16 2024, 1:53 AM
Unknown Object (File)
Sep 12 2024, 1:47 PM
Unknown Object (File)
Sep 12 2024, 2:49 AM
Unknown Object (File)
Sep 10 2024, 2:33 AM
Subscribers
None

Details

Summary

Ref T12932. For long-lived installs, one of the largest tables tends to be the hunk data table. Although it doesn't grow tremendously fast, it's also well suited to storage in Files instead of the database (infrequent access, relatively large blobs of data, mostly one-at-a-time access), and earlier work anticipated eventually adding support for Files storage.

Make Files storage work, and provide bin/differential migrate-hunk to manually test/migrate hunks. This is currently the only way hunks get moved to file storage, but I expect to add a GC step which moves them to File storage after 30 days shortly.

The immediate motivation for this is to relieve storage pressure on db001/db002 so we have more headroom for deploying the Ferret engine and its larger indexes (see also T12819).

Test Plan
  • Used bin/differential migrate-hunk to move a hunk to and from file storage, verified it survived intact.
  • Downloaded the actual stored file, sanity-checked it. Verified permissions.
  • Destroyed a diff with bin/remove destroy, saw the hunk and file storage destroyed.
  • Verified that going from file -> text destroys the old file properly with migrate-hunk --trace ....

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable