1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2025-01-20 19:51:08 +01:00
phorge-phorge/src/applications/diffusion/query/lowlevel
epriestley d98eb2c8b8 Provide a fast path for resolving repository refs
Summary:
Ref T2783. With service-oriented calls, we take a larger performacne hit than necessary resolving refs.

Instead of resolving refs over the wire, try to resolve them from the database first. This can resolve almost all refs (commit hashes, branch and tag names).

This can't resolve weird refs like `master~50`, and obviously can't resolve invalid refs. In those cases we'll go back to the old logic, call `diffusion.resolverefs`, and end up with the right result.

Test Plan:
  - Browsed repositories in Diffusion.
  - Verified that service repositories no longer make unnecessary `diffusion.resolverefs` calls for common refs (branch names, commit hashes).
  - Resolved refs like `master~50`, saw call to underlying VCS and correct result.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T2783

Differential Revision: https://secure.phabricator.com/D11476
2015-01-23 13:31:17 -08:00
..
DiffusionLowLevelCommitFieldsQuery.php Fix visibility of DiffusionLowLevelQuery::executeQuery() methods 2015-01-16 06:56:33 +11:00
DiffusionLowLevelCommitQuery.php Fix visibility of DiffusionLowLevelQuery::executeQuery() methods 2015-01-16 06:56:33 +11:00
DiffusionLowLevelGitRefQuery.php Change double quotes to single quotes. 2014-06-09 11:36:50 -07:00
DiffusionLowLevelMercurialBranchesQuery.php Never use "{branches}" in Mercurial 2014-06-20 11:48:31 -07:00
DiffusionLowLevelMercurialPathsQuery.php Diffusion - replace last hg manifest call with hg locate 2014-08-28 13:08:42 -07:00
DiffusionLowLevelParentsQuery.php Fix visibility of DiffusionLowLevelQuery::executeQuery() methods 2015-01-16 06:56:33 +11:00
DiffusionLowLevelQuery.php Change double quotes to single quotes. 2014-06-09 11:36:50 -07:00
DiffusionLowLevelResolveRefsQuery.php Provide a fast path for resolving repository refs 2015-01-23 13:31:17 -08:00