Page MenuHomePhabricator

Record parent relationships when discovering commits
ClosedPublic

Authored by epriestley on May 10 2014, 7:46 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Mar 1, 11:27 PM
Unknown Object (File)
Wed, Feb 19, 12:56 PM
Unknown Object (File)
Thu, Feb 13, 2:16 AM
Unknown Object (File)
Sun, Feb 9, 12:45 PM
Unknown Object (File)
Sun, Feb 9, 12:45 PM
Unknown Object (File)
Sun, Feb 9, 12:45 PM
Unknown Object (File)
Sun, Feb 9, 12:45 PM
Unknown Object (File)
Thu, Feb 6, 3:17 AM

Details

Summary

Ref T4455. This adds a repository_parents table which stores <childCommitID, parentCommitID> relationships.

For new commits, it is populated when commits are discovered.

For older commits, there's a bin/repository parents script to rebuild the data.

Right now, there's no UI suggestion that you should run the script. I haven't come up with a super clean way to do this, and this table will only improve performance for now, so it's not important that we get everyone to run the script right away. I'm just leaving it for the moment, and we can figure out how to tell admins to run it later.

The ultimate goal is to solve T2683, but solving T4455 gets us some stuff anyway (for example, we can serve diffusion.commitparentsquery faster out of this cache).

Test Plan
  • Used bin/repository discover to discover new commits in Git, SVN and Mercurial repositories.
  • Used bin/repository parents to rebuild Git and Mercurial repositories (SVN repos just exit with a message).
  • Verified that the table appears to be sensible.

Diff Detail

Repository
rP Phabricator
Branch
gcache1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 347
Build 347: [Placeholder Plan] Wait for 30 Seconds

Event Timeline

epriestley retitled this revision from to Record parent relationships when discovering commits.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: btrahan.
btrahan edited edge metadata.
This revision is now accepted and ready to land.May 12 2014, 5:06 PM
epriestley updated this revision to Diff 21566.

Closed by commit rP95eab2f3b0f2 (authored by @epriestley).