Page MenuHomePhabricator

Add a unique key to OwnersPath on "<packageID, repositoryPHID, pathIndex>"
ClosedPublic

Authored by epriestley on Mar 7 2018, 3:47 AM.
Tags
None
Referenced Files
F15412737: D19182.diff
Wed, Mar 19, 2:39 PM
F15391612: D19182.id45949.diff
Sat, Mar 15, 10:45 AM
F15391328: D19182.id45949.diff
Sat, Mar 15, 9:24 AM
F15390234: D19182.id45949.diff
Sat, Mar 15, 6:03 AM
F15388848: D19182.id45944.diff
Sat, Mar 15, 4:31 AM
F15387734: D19182.diff
Sat, Mar 15, 2:49 AM
F15301906: D19182.id45949.diff
Wed, Mar 5, 6:21 PM
Unknown Object (File)
Feb 9 2025, 5:37 AM
Subscribers
None

Details

Summary

Depends on D19181. Ref T11015. This nukes duplicates from the table if they exist, then adds a unique key.

(Duplicates should not exist and can not be added with any recent version of the web UI.)

Test Plan
  • Tried to add duplicates with web UI, didn't have any luck.
  • Explicitly added duplicates with manual INSERTs.
  • Viewed packages in web UI and saw duplicates.
  • Ran migrations, got a clean purge and a nice unique key.
  • There's still no way to actually hit a duplicate key error in the UI (unless you can collide hashes, I suppose), this is purely a correctness/robustness change.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable