Ref T4068. Partly, this moves discovery to the more unit-testable PhabricatorRepositoryDiscoveryEngine. It also fixes some issues, see inlines.
Details
Details
- Reviewers
btrahan - Maniphest Tasks
- T4068: Importing a very large repository does not complete correctly
- Commits
- Restricted Diffusion Commit
rP5b873a74de94: Move Mercurial discovery to PhabricatorRepositoryDiscoveryEngine
In a Mercurial repository, ran bin/repository discover --repair, verified commits came out topographically sorted. Ran without --repair and in various other contexts, like with no commits to discover and some-but-not-all commits to discover.
Diff Detail
Diff Detail
- Lint
Lint Skipped - Unit
Tests Skipped
Event Timeline
src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php | ||
---|---|---|
790–798 | This is a bug. Commits are not inserted in topographical order, or even sort-of-topographical order. Instead, they're inserted in roughly-newest-to-oldest order, which is extremely bad and means we can't recover if we die halfway through. This is the primary issue this diff fixes. Discovery is fully safe and resumable if ancestors are always inserted before children. | |
src/applications/repository/engine/PhabricatorRepositoryDiscoveryEngine.php | ||
46–52 | Git is a bit more ocmplicated so I haven't moved it over yet. | |
228–243 | Thanks for writing this, it made my job a lot easier. :) |
src/applications/repository/engine/PhabricatorRepositoryDiscoveryEngine.php | ||
---|---|---|
228–243 | NP :D |