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
F13276121: D19182.diff
Fri, May 31, 5:34 AM
F13226232: D19182.id45949.diff
Sun, May 19, 7:52 PM
F13225324: D19182.id45949.diff
Sun, May 19, 2:38 PM
F13222061: D19182.diff
Sun, May 19, 3:19 AM
F13204595: D19182.diff
Wed, May 15, 12:44 AM
F13192421: D19182.id.diff
Sun, May 12, 7:14 AM
F13191418: D19182.id45944.diff
Sat, May 11, 8:44 PM
F13187606: D19182.diff
Sat, May 11, 4:38 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